[sr-dev] git:master: rtpproxy(k): 64 bit warning fixes

Andrei Pelinescu-Onciul andrei at iptel.org
Tue Oct 5 20:06:31 CEST 2010


Module: sip-router
Branch: master
Commit: b92ad85f26c48199cc321ace8738ec5387266217
URL:    http://git.sip-router.org/cgi-bin/gitweb.cgi/sip-router/?a=commit;h=b92ad85f26c48199cc321ace8738ec5387266217

Author: Andrei Pelinescu-Onciul <andrei at iptel.org>
Committer: Andrei Pelinescu-Onciul <andrei at iptel.org>
Date:   Tue Oct  5 20:04:50 2010 +0200

rtpproxy(k): 64 bit warning fixes

- "%d" in format and long arg.
- int to pointer conversion

---

 modules_k/rtpproxy/rtpproxy_funcs.c  |    2 +-
 modules_k/rtpproxy/rtpproxy_stream.c |    2 +-
 2 files changed, 2 insertions(+), 2 deletions(-)

diff --git a/modules_k/rtpproxy/rtpproxy_funcs.c b/modules_k/rtpproxy/rtpproxy_funcs.c
index 2cb4659..fe82277 100644
--- a/modules_k/rtpproxy/rtpproxy_funcs.c
+++ b/modules_k/rtpproxy/rtpproxy_funcs.c
@@ -199,7 +199,7 @@ int extract_body(struct sip_msg *msg, str *body )
 
 	if (body->len + body->s > msg->buf + msg->len) {
 		LM_ERR("content-length exceeds packet-length by %d\n",
-				(body->len + body->s) - (msg->buf + msg->len));
+				(int)((body->len + body->s) - (msg->buf + msg->len)));
 		goto error;
 	}
 
diff --git a/modules_k/rtpproxy/rtpproxy_stream.c b/modules_k/rtpproxy/rtpproxy_stream.c
index 4065b01..20693e0 100644
--- a/modules_k/rtpproxy/rtpproxy_stream.c
+++ b/modules_k/rtpproxy/rtpproxy_stream.c
@@ -63,7 +63,7 @@ fixup_var_str_int(void **param, int param_no)
 	s.len = strlen(s.s);
 	if (str2sint(&s, &ret)==0) {
 		pkg_free(*param);
-		*param = (void *)ret;
+		*param = (void *)(long)ret;
         } else {
             LM_ERR("bad number <%s>\n", (char *)(*param));
             return E_CFG;




More information about the sr-dev mailing list