[sr-dev] git:master:82e22fb3: pua: copy over subs flag in subscribe_cbparam()
Daniel-Constantin Mierla
miconda at gmail.com
Fri Oct 28 16:09:52 CEST 2016
Module: kamailio
Branch: master
Commit: 82e22fb36c5155d920b60e8cad689578eec8fb70
URL: https://github.com/kamailio/kamailio/commit/82e22fb36c5155d920b60e8cad689578eec8fb70
Author: Daniel-Constantin Mierla <miconda at gmail.com>
Committer: Daniel-Constantin Mierla <miconda at gmail.com>
Date: 2016-10-28T16:09:40+02:00
pua: copy over subs flag in subscribe_cbparam()
---
Modified: modules/pua/send_subscribe.c
---
Diff: https://github.com/kamailio/kamailio/commit/82e22fb36c5155d920b60e8cad689578eec8fb70.diff
Patch: https://github.com/kamailio/kamailio/commit/82e22fb36c5155d920b60e8cad689578eec8fb70.patch
---
diff --git a/modules/pua/send_subscribe.c b/modules/pua/send_subscribe.c
index 84b69f8..0998119 100644
--- a/modules/pua/send_subscribe.c
+++ b/modules/pua/send_subscribe.c
@@ -755,14 +755,14 @@ void subs_cback_func(struct cell *t, int cb_type, struct tmcb_params *ps)
}
ua_pres_t* subscribe_cbparam(subs_info_t* subs, int ua_flag)
-{
+{
ua_pres_t* hentity= NULL;
int size;
size= sizeof(ua_pres_t)+ 2*sizeof(str)+(subs->pres_uri->len+
subs->watcher_uri->len+ subs->contact->len+ subs->id.len+ 1)*
sizeof(char);
-
+
if(subs->outbound_proxy && subs->outbound_proxy->len && subs->outbound_proxy->s )
size+= sizeof(str)+ subs->outbound_proxy->len* sizeof(char);
@@ -811,7 +811,7 @@ ua_pres_t* subscribe_cbparam(subs_info_t* subs, int ua_flag)
memcpy(hentity->outbound_proxy->s, subs->outbound_proxy->s, subs->outbound_proxy->len);
hentity->outbound_proxy->len= subs->outbound_proxy->len;
size+= subs->outbound_proxy->len;
- }
+ }
if(subs->expires< 0)
hentity->desired_expires= 0;
else
@@ -833,21 +833,21 @@ ua_pres_t* subscribe_cbparam(subs_info_t* subs, int ua_flag)
}
hentity->flag= subs->source_flag;
hentity->event= subs->event;
- hentity->ua_flag= hentity->ua_flag;
+ hentity->ua_flag= subs->ua_flag;
hentity->cb_param= subs->cb_param;
return hentity;
-}
+}
ua_pres_t* subs_cbparam_indlg(ua_pres_t* subs, int expires, int ua_flag)
-{
+{
ua_pres_t* hentity= NULL;
int size;
size= sizeof(ua_pres_t)+ 2*sizeof(str)+subs->pres_uri->len+
subs->watcher_uri->len+ subs->contact.len+ subs->id.len+
subs->to_tag.len+ subs->call_id.len+ subs->from_tag.len+ 1;
-
+
if(subs->outbound_proxy && subs->outbound_proxy->len && subs->outbound_proxy->s )
size+= sizeof(str)+ subs->outbound_proxy->len;
More information about the sr-dev
mailing list