diff options
author | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-06-17 20:30:00 +0000 |
---|---|---|
committer | mmichelson <mmichelson@f38db490-d61c-443f-a65b-d21fe96a405b> | 2008-06-17 20:30:00 +0000 |
commit | e6bc4720e8a7c8f5717e709a13c539945f006c5d (patch) | |
tree | d31f22229a895a69c2ec7ae57aba00ed90d99524 /channels | |
parent | a5639fe1f4f0097587f44b5b038aa49354f5a88e (diff) |
Merged revisions 123486 via svnmerge from
https://origsvn.digium.com/svn/asterisk/trunk
................
r123486 | mmichelson | 2008-06-17 15:28:47 -0500 (Tue, 17 Jun 2008) | 12 lines
Merged revisions 123485 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4
........
r123485 | mmichelson | 2008-06-17 15:26:38 -0500 (Tue, 17 Jun 2008) | 4 lines
Make chan_sip build under dev mode with compilers >= GCC 4.2
Thanks to jpeeler for alerting me of this
........
................
git-svn-id: http://svn.digium.com/svn/asterisk/branches/1.6.0@123487 f38db490-d61c-443f-a65b-d21fe96a405b
Diffstat (limited to 'channels')
-rw-r--r-- | channels/chan_sip.c | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c index 3bcf5d42a..4ef70ce51 100644 --- a/channels/chan_sip.c +++ b/channels/chan_sip.c @@ -15150,8 +15150,10 @@ static void handle_response(struct sip_pvt *p, int resp, char *rest, struct sip_ int sipmethod; int res = 1; const char *c = get_header(req, "Cseq"); + /* GCC 4.2 complains if I try to cast c as a char * when passing it to ast_skip_nonblanks, so make a copy of it */ + char *c_copy = ast_strdupa(c); /* Skip the Cseq and its subsequent spaces */ - const char *msg = ast_skip_blanks(ast_skip_nonblanks((char *)c)); + const char *msg = ast_skip_blanks(ast_skip_nonblanks(c_copy)); if (!msg) msg = ""; |