aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authoroej <oej@f38db490-d61c-443f-a65b-d21fe96a405b>2006-03-15 13:06:48 +0000
committeroej <oej@f38db490-d61c-443f-a65b-d21fe96a405b>2006-03-15 13:06:48 +0000
commit0d78044c573eabb6210da8fd9833fc64380160eb (patch)
tree04bae0d934f9696b22005fc7bc0de546b0fd1759
parent828186da1f75333e5e1016ee7045d797fa73a473 (diff)
Import of rev 13026 from 1.2 branch: Fix parameters to event: header
in SUBSCRIBE request git-svn-id: http://svn.digium.com/svn/asterisk/trunk@13027 f38db490-d61c-443f-a65b-d21fe96a405b
-rw-r--r--channels/chan_sip.c8
1 files changed, 8 insertions, 0 deletions
diff --git a/channels/chan_sip.c b/channels/chan_sip.c
index 27bf02754..426fb93de 100644
--- a/channels/chan_sip.c
+++ b/channels/chan_sip.c
@@ -10848,10 +10848,18 @@ static int handle_request_subscribe(struct sip_pvt *p, struct sip_request *req,
char mailboxbuf[256]="";
char *mailbox = NULL;
int mailboxsize = 0;
+ char *eventparam;
char *event = get_header(req, "Event"); /* Get Event package name */
char *accept = get_header(req, "Accept");
+ /* Find parameters to Event: header value and remove them for now */
+ eventparam = strchr(event, ";");
+ if (eventparam) {
+ *eventparam = '\0';
+ eventparam++;
+ }
+
if (!strcmp(event, "message-summary") && !strcmp(accept, "application/simple-message-summary")) {
mailbox = mailboxbuf;
mailboxsize = sizeof(mailboxbuf);