summaryrefslogtreecommitdiff
path: root/channels
diff options
context:
space:
mode:
authorJoshua Colp <jcolp@digium.com>2007-11-02 20:22:40 +0000
committerJoshua Colp <jcolp@digium.com>2007-11-02 20:22:40 +0000
commita7c6c47e61440ce52eef5ecb6f3134e276ddd629 (patch)
tree20ffa15e898a09eecdfbe899c7fd0369aaf45630 /channels
parentdffa53f718717a8630b3ee6f36d0366a585de8a1 (diff)
Merged revisions 88328 via svnmerge from
https://origsvn.digium.com/svn/asterisk/branches/1.4 ........ r88328 | file | 2007-11-02 17:20:21 -0300 (Fri, 02 Nov 2007) | 6 lines If an INFO request within a dialog is received with a content length of 0 simply send back a 200 OK. It is valid to do this and the remote side is probably using it to make sure the signalling is still alive. (closes issue #5747) Reported by: chandi Patches: infofix-81430-1.patch uploaded by IgorG (license 20) ........ git-svn-id: https://origsvn.digium.com/svn/asterisk/trunk@88329 65c4cc65-6c06-0410-ace0-fbb531ad65f3
Diffstat (limited to 'channels')
-rw-r--r--channels/chan_sip.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index bd1feed3c..61e36051d 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -12341,7 +12341,12 @@ static void handle_request_info(struct sip_pvt *p, struct sip_request *req)
ast_debug(1, "Got a Request to Record the channel, state %s\n", c);
transmit_response(p, "200 OK", req);
return;
+ } else if (ast_strlen_zero(c = get_header(req, "Content-Length")) || !strcasecmp(c, "0")) {
+ /* This is probably just a packet making sure the signalling is still up, just send back a 200 OK */
+ transmit_response(p, "200 OK", req);
+ return;
}
+
/* Other type of INFO message, not really understood by Asterisk */
/* if (get_msg_text(buf, sizeof(buf), req)) { */