kamailio.org
Sign In
Sign Up
Sign In
Sign Up
Manage this list
×
Keyboard Shortcuts
Thread View
j
: Next unread message
k
: Previous unread message
j a
: Jump to all threads
j l
: Jump to MailingList overview
2024
November
October
September
August
July
June
May
April
March
February
January
2023
December
November
October
September
August
July
June
May
April
March
February
January
2022
December
November
October
September
August
July
June
May
April
March
February
January
2021
December
November
October
September
August
July
June
May
April
March
February
January
2020
December
November
October
September
August
July
June
May
April
March
February
January
2019
December
November
October
September
August
July
June
May
April
March
February
January
2018
December
November
October
September
August
July
June
May
April
March
February
January
2017
December
November
October
September
August
July
June
May
April
March
February
January
2016
December
November
October
September
August
July
June
May
April
March
February
January
2015
December
November
October
September
August
July
June
May
April
March
February
January
2014
December
November
October
September
August
July
June
May
April
March
February
January
2013
December
November
October
September
August
July
June
May
April
March
February
January
2012
December
November
October
September
August
July
June
May
April
March
February
January
2011
December
November
October
September
August
July
June
May
April
March
February
January
2010
December
November
October
September
August
July
June
May
April
March
February
January
2009
December
November
October
September
August
July
June
May
April
March
February
January
2008
December
November
List overview
Download
sr-dev
July 2017
----- 2024 -----
November 2024
October 2024
September 2024
August 2024
July 2024
June 2024
May 2024
April 2024
March 2024
February 2024
January 2024
----- 2023 -----
December 2023
November 2023
October 2023
September 2023
August 2023
July 2023
June 2023
May 2023
April 2023
March 2023
February 2023
January 2023
----- 2022 -----
December 2022
November 2022
October 2022
September 2022
August 2022
July 2022
June 2022
May 2022
April 2022
March 2022
February 2022
January 2022
----- 2021 -----
December 2021
November 2021
October 2021
September 2021
August 2021
July 2021
June 2021
May 2021
April 2021
March 2021
February 2021
January 2021
----- 2020 -----
December 2020
November 2020
October 2020
September 2020
August 2020
July 2020
June 2020
May 2020
April 2020
March 2020
February 2020
January 2020
----- 2019 -----
December 2019
November 2019
October 2019
September 2019
August 2019
July 2019
June 2019
May 2019
April 2019
March 2019
February 2019
January 2019
----- 2018 -----
December 2018
November 2018
October 2018
September 2018
August 2018
July 2018
June 2018
May 2018
April 2018
March 2018
February 2018
January 2018
----- 2017 -----
December 2017
November 2017
October 2017
September 2017
August 2017
July 2017
June 2017
May 2017
April 2017
March 2017
February 2017
January 2017
----- 2016 -----
December 2016
November 2016
October 2016
September 2016
August 2016
July 2016
June 2016
May 2016
April 2016
March 2016
February 2016
January 2016
----- 2015 -----
December 2015
November 2015
October 2015
September 2015
August 2015
July 2015
June 2015
May 2015
April 2015
March 2015
February 2015
January 2015
----- 2014 -----
December 2014
November 2014
October 2014
September 2014
August 2014
July 2014
June 2014
May 2014
April 2014
March 2014
February 2014
January 2014
----- 2013 -----
December 2013
November 2013
October 2013
September 2013
August 2013
July 2013
June 2013
May 2013
April 2013
March 2013
February 2013
January 2013
----- 2012 -----
December 2012
November 2012
October 2012
September 2012
August 2012
July 2012
June 2012
May 2012
April 2012
March 2012
February 2012
January 2012
----- 2011 -----
December 2011
November 2011
October 2011
September 2011
August 2011
July 2011
June 2011
May 2011
April 2011
March 2011
February 2011
January 2011
----- 2010 -----
December 2010
November 2010
October 2010
September 2010
August 2010
July 2010
June 2010
May 2010
April 2010
March 2010
February 2010
January 2010
----- 2009 -----
December 2009
November 2009
October 2009
September 2009
August 2009
July 2009
June 2009
May 2009
April 2009
March 2009
February 2009
January 2009
----- 2008 -----
December 2008
November 2008
sr-dev@lists.kamailio.org
23 participants
410 discussions
Start a n
N
ew thread
git:master:1f50cd26: pv: remove useless condition
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: 1f50cd26ba0db88fd5f2c33e2b44a461f471e760 URL:
https://github.com/kamailio/kamailio/commit/1f50cd26ba0db88fd5f2c33e2b44a46…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2017-07-27T13:13:21+02:00 pv: remove useless condition --- Modified: src/modules/pv/pv_trans.c --- Diff:
https://github.com/kamailio/kamailio/commit/1f50cd26ba0db88fd5f2c33e2b44a46…
Patch:
https://github.com/kamailio/kamailio/commit/1f50cd26ba0db88fd5f2c33e2b44a46…
--- diff --git a/src/modules/pv/pv_trans.c b/src/modules/pv/pv_trans.c index 3012126ff6..62574c46f5 100644 --- a/src/modules/pv/pv_trans.c +++ b/src/modules/pv/pv_trans.c @@ -2534,11 +2534,10 @@ char* tr_parse_uri(str* in, trans_t *t) LM_ERR("unknown transformation: %.*s/%.*s!\n", in->len, in->s, name.len, name.s); error: - if(tp) - tr_param_free(tp); if(spec) pv_spec_free(spec); return NULL; + done: t->name = name; return p;
7 years, 3 months
1
0
0
0
git:master:2d68418a: msrp: use formated string instead of complex sequence of concatenation
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: 2d68418a6df8d814e60f992b3ae1d74fbb13a2f3 URL:
https://github.com/kamailio/kamailio/commit/2d68418a6df8d814e60f992b3ae1d74…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2017-07-27T13:09:02+02:00 msrp: use formated string instead of complex sequence of concatenation --- Modified: src/modules/msrp/msrp_cmap.c --- Diff:
https://github.com/kamailio/kamailio/commit/2d68418a6df8d814e60f992b3ae1d74…
Patch:
https://github.com/kamailio/kamailio/commit/2d68418a6df8d814e60f992b3ae1d74…
--- diff --git a/src/modules/msrp/msrp_cmap.c b/src/modules/msrp/msrp_cmap.c index 3648df41b9..bdcccbd6fe 100644 --- a/src/modules/msrp/msrp_cmap.c +++ b/src/modules/msrp/msrp_cmap.c @@ -210,20 +210,16 @@ int msrp_cmap_save(msrp_frame_t *mf) hid = msrp_get_hashid(&_msrp_sruid.uid); idx = msrp_get_slot(hid, _msrp_cmap_head->mapsize); - srcaddr.s = sbuf; - if (msrp_tls_module_loaded) - { - memcpy(srcaddr.s, "msrps://", 8); - srcaddr.s+=8; - } else { - memcpy(srcaddr.s, "msrp://", 7); - srcaddr.s+=7; + srcaddr.len = snprintf(sbuf, MSRP_SBUF_SIZE, "msrp%s://%s:%d", + (msrp_tls_module_loaded)?"s":"", + ip_addr2a(&mf->tcpinfo->rcv->src_ip), + (int)mf->tcpinfo->rcv->src_port); + if(srcaddr.len<0 || srcaddr.len>=MSRP_SBUF_SIZE) { + LM_ERR("failure or address lenght too big (%d)\n", srcaddr.len); + return -1; } - strcpy(srcaddr.s, ip_addr2a(&mf->tcpinfo->rcv->src_ip)); - strcat(srcaddr.s, ":"); - strcat(srcaddr.s, int2str(mf->tcpinfo->rcv->src_port, NULL)); srcaddr.s = sbuf; - srcaddr.len = strlen(srcaddr.s); + srcsock = mf->tcpinfo->rcv->bind_address->sock_str; LM_DBG("saving connection info for [%.*s] [%.*s] (%u/%u)\n", fpeer.len, fpeer.s, _msrp_sruid.uid.len, _msrp_sruid.uid.s,
7 years, 3 months
1
0
0
0
git:master:6d3a97d1: ldap: free in case of error cases
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: 6d3a97d1c3e62f876bbb7a17927b2a40243ec268 URL:
https://github.com/kamailio/kamailio/commit/6d3a97d1c3e62f876bbb7a17927b2a4…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2017-07-27T13:08:19+02:00 ldap: free in case of error cases --- Modified: src/modules/ldap/ld_session.c Modified: src/modules/ldap/ldap_mod.c --- Diff:
https://github.com/kamailio/kamailio/commit/6d3a97d1c3e62f876bbb7a17927b2a4…
Patch:
https://github.com/kamailio/kamailio/commit/6d3a97d1c3e62f876bbb7a17927b2a4…
--- diff --git a/src/modules/ldap/ld_session.c b/src/modules/ldap/ld_session.c index 25ad429c42..8a27d08004 100644 --- a/src/modules/ldap/ld_session.c +++ b/src/modules/ldap/ld_session.c @@ -62,6 +62,7 @@ int add_ld_session(char* _name, LDAP* _ldh, dictionary* _d) new_lds->host_name = (char*)pkg_malloc(strlen(host_name)+1); if (new_lds->host_name == NULL) { LM_ERR("no memory\n"); + pkg_free(new_lds); return -1; } strcpy(new_lds->host_name, host_name); @@ -117,6 +118,8 @@ int add_ld_session(char* _name, LDAP* _ldh, dictionary* _d) new_lds->bind_dn = (char*)pkg_malloc(strlen(bind_dn)+1); if (new_lds->bind_dn == NULL) { LM_ERR("no memory\n"); + pkg_free(new_lds->host_name); + pkg_free(new_lds); return -1; } strcpy(new_lds->bind_dn, bind_dn); @@ -129,6 +132,9 @@ int add_ld_session(char* _name, LDAP* _ldh, dictionary* _d) new_lds->bind_pwd = (char*)pkg_malloc(strlen(bind_pwd)+1); if (new_lds->bind_pwd == NULL) { LM_ERR("no memory\n"); + pkg_free(new_lds->bind_dn); + pkg_free(new_lds->host_name); + pkg_free(new_lds); return -1; } strcpy(new_lds->bind_pwd, bind_pwd); diff --git a/src/modules/ldap/ldap_mod.c b/src/modules/ldap/ldap_mod.c index 89eb89cb99..59367a83c8 100644 --- a/src/modules/ldap/ldap_mod.c +++ b/src/modules/ldap/ldap_mod.c @@ -447,6 +447,7 @@ static int ldap_result_check_fixup(void** param, int param_no) if (pv_parse_format(&s, &(lp->check_str_elem_p)) < 0) { LM_ERR("pv_parse_format failed\n"); + pkg_free(lp); return E_OUT_OF_MEM; } }
7 years, 3 months
1
0
0
0
git:master:67bd0803: lcr: check return for rewrite_uri() and do memset with size of alloc
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: 67bd080310c5b8371d9943fa964e81154c916356 URL:
https://github.com/kamailio/kamailio/commit/67bd080310c5b8371d9943fa964e811…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2017-07-27T12:42:42+02:00 lcr: check return for rewrite_uri() and do memset with size of alloc --- Modified: src/modules/lcr/lcr_mod.c --- Diff:
https://github.com/kamailio/kamailio/commit/67bd080310c5b8371d9943fa964e811…
Patch:
https://github.com/kamailio/kamailio/commit/67bd080310c5b8371d9943fa964e811…
--- diff --git a/src/modules/lcr/lcr_mod.c b/src/modules/lcr/lcr_mod.c index 1313d65aff..02bad0bb5e 100644 --- a/src/modules/lcr/lcr_mod.c +++ b/src/modules/lcr/lcr_mod.c @@ -709,8 +709,7 @@ static int mod_init(void) LM_ERR("no memory for gw table\n"); goto err; } - memset(gw_pt[i], 0, sizeof(struct gw_info *) * - (lcr_gw_count_param + 1)); + memset(gw_pt[i], 0, sizeof(struct gw_info) * (lcr_gw_count_param + 1)); } /* Allocate and initialize locks */ @@ -2750,7 +2749,10 @@ static int next_gw(struct sip_msg* _m, char* _s1, char* _s2) /* Rewrite Request URI */ uri_str.s = r_uri; uri_str.len = r_uri_len; - rewrite_uri(_m, &uri_str); + if(rewrite_uri(_m, &uri_str)<0) { + LM_ERR("failed to rewrite uri\n"); + return -1; + } /* Set Destination URI if not empty */ if (dst_uri_len > 0) { @@ -2759,7 +2761,7 @@ static int next_gw(struct sip_msg* _m, char* _s1, char* _s2) LM_DBG("setting du to <%.*s>\n", uri_str.len, uri_str.s); rval = set_dst_uri(_m, &uri_str); if (rval != 0) { - LM_ERR("calling do_action failed with return value <%d>\n", rval); + LM_ERR("calling set dst uri failed with return value <%d>\n", rval); return -1; }
7 years, 3 months
1
0
0
0
git:master:0fd33d76: imc: better check for buffer size limit
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: 0fd33d766c471e0f0710bd6f84898462420bfbaa URL:
https://github.com/kamailio/kamailio/commit/0fd33d766c471e0f0710bd6f8489846…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2017-07-27T11:34:35+02:00 imc: better check for buffer size limit --- Modified: src/modules/imc/imc.c Modified: src/modules/imc/imc_cmd.c --- Diff:
https://github.com/kamailio/kamailio/commit/0fd33d766c471e0f0710bd6f8489846…
Patch:
https://github.com/kamailio/kamailio/commit/0fd33d766c471e0f0710bd6f8489846…
--- diff --git a/src/modules/imc/imc.c b/src/modules/imc/imc.c index 8876b248a1..2ae31c997c 100644 --- a/src/modules/imc/imc.c +++ b/src/modules/imc/imc.c @@ -304,11 +304,6 @@ int add_from_db(void) imc_dbf.free_result(imc_db, r_res); r_res = NULL; } - if(m_res) - { - imc_dbf.free_result(imc_db, m_res); - m_res = NULL; - } return 0; diff --git a/src/modules/imc/imc_cmd.c b/src/modules/imc/imc_cmd.c index 781bf57cfe..1514e2c956 100644 --- a/src/modules/imc/imc_cmd.c +++ b/src/modules/imc/imc_cmd.c @@ -467,8 +467,7 @@ int imc_handle_invite(struct sip_msg* msg, imc_cmd_t *cmd, } body.len = 13 + member->uri.len - 4/* sip: */ + 28; - if(body.len>=IMC_BUF_SIZE || member->uri.len>=IMC_BUF_SIZE - || room->uri.len>=IMC_BUF_SIZE) + if(body.len>=IMC_BUF_SIZE-1) { LM_ERR("buffer size overflow\n"); goto error;
7 years, 3 months
1
0
0
0
git:master:eb6c9462: http_client: safety check for lenght of retrieved headers
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: eb6c94626d02e5a6fc2c93328591c140853535da URL:
https://github.com/kamailio/kamailio/commit/eb6c94626d02e5a6fc2c93328591c14…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2017-07-27T11:33:44+02:00 http_client: safety check for lenght of retrieved headers --- Modified: src/modules/http_client/functions.c --- Diff:
https://github.com/kamailio/kamailio/commit/eb6c94626d02e5a6fc2c93328591c14…
Patch:
https://github.com/kamailio/kamailio/commit/eb6c94626d02e5a6fc2c93328591c14…
--- diff --git a/src/modules/http_client/functions.c b/src/modules/http_client/functions.c index ea194250ed..c4fc39d6a4 100644 --- a/src/modules/http_client/functions.c +++ b/src/modules/http_client/functions.c @@ -333,8 +333,8 @@ static int curL_query_url(struct sip_msg* _m, const char* _url, str* _dst, /* HTTP_CODE CHANGED TO CURLINFO_RESPONSE_CODE in curl > 7.10.7 */ curl_easy_getinfo(curl, CURLINFO_HTTP_CODE, &stat); if(res == CURLE_OK) { - char *ct; - char *url; + char *ct = NULL; + char *url = NULL; /* ask for the content-type of the response */ res = curl_easy_getinfo(curl, CURLINFO_CONTENT_TYPE, &ct); @@ -342,14 +342,16 @@ static int curL_query_url(struct sip_msg* _m, const char* _url, str* _dst, if(ct) { LM_DBG("We received Content-Type: %s\n", ct); - if (params->pconn) { + if (params->pconn && + strlen(ct)<sizeof(params->pconn->result_content_type)-1) { strncpy(params->pconn->result_content_type, ct, sizeof(params->pconn->result_content_type)); } } if(url) { LM_DBG("We visited URL: %s\n", url); - if (params->pconn) { + if (params->pconn + && strlen(url)<sizeof(params->pconn->redirecturl)-1) { strncpy(params->pconn->redirecturl, url , sizeof(params->pconn->redirecturl)); }
7 years, 3 months
1
0
0
0
git:master:00f2cfd1: http_async_client: safety check for cell value
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: 00f2cfd1efb81030c705cf4b4f6aa3ac582d3059 URL:
https://github.com/kamailio/kamailio/commit/00f2cfd1efb81030c705cf4b4f6aa3a…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2017-07-27T11:32:56+02:00 http_async_client: safety check for cell value --- Modified: src/modules/http_async_client/http_multi.c --- Diff:
https://github.com/kamailio/kamailio/commit/00f2cfd1efb81030c705cf4b4f6aa3a…
Patch:
https://github.com/kamailio/kamailio/commit/00f2cfd1efb81030c705cf4b4f6aa3a…
--- diff --git a/src/modules/http_async_client/http_multi.c b/src/modules/http_async_client/http_multi.c index 5d07a9d29a..7e086e4b03 100644 --- a/src/modules/http_async_client/http_multi.c +++ b/src/modules/http_async_client/http_multi.c @@ -314,7 +314,9 @@ void reply_error(struct http_m_cell *cell) reply->error[0] = '\0'; } - cell->cb(reply, cell->param); + if (cell) { + cell->cb(reply, cell->param); + } pkg_free(reply);
7 years, 3 months
1
0
0
0
git:master:36202503: drouting: handle errors in fixup function
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: 36202503c531e5e6e865da018a59a494da6d9dc3 URL:
https://github.com/kamailio/kamailio/commit/36202503c531e5e6e865da018a59a49…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2017-07-27T11:30:22+02:00 drouting: handle errors in fixup function --- Modified: src/modules/drouting/drouting.c Modified: src/modules/drouting/prefix_tree.c --- Diff:
https://github.com/kamailio/kamailio/commit/36202503c531e5e6e865da018a59a49…
Patch:
https://github.com/kamailio/kamailio/commit/36202503c531e5e6e865da018a59a49…
--- diff --git a/src/modules/drouting/drouting.c b/src/modules/drouting/drouting.c index e18ce7f76d..d642716a3d 100644 --- a/src/modules/drouting/drouting.c +++ b/src/modules/drouting/drouting.c @@ -979,6 +979,11 @@ static int fixup_do_routing(void** param, int param_no) if (param_no==1) { + if ( s==NULL || s[0]==0 ) { + LM_CRIT("empty group id definition"); + return E_CFG; + } + drg = (dr_group_t*)pkg_malloc(sizeof(dr_group_t)); if(drg==NULL) { @@ -987,33 +992,31 @@ static int fixup_do_routing(void** param, int param_no) } memset(drg, 0, sizeof(dr_group_t)); - if ( s==NULL || s[0]==0 ) { - LM_CRIT("empty group id definition"); - return E_CFG; - } - if (s[0]=='$') { /* param is a PV (AVP only supported) */ r.s = s; r.len = strlen(s); if (pv_parse_spec( &r, &avp_spec)==0 - || avp_spec.type!=PVT_AVP) { + || avp_spec.type!=PVT_AVP) { LM_ERR("malformed or non AVP %s AVP definition\n", s); + pkg_free(drg); return E_CFG; } if( pv_get_avp_name(0, &(avp_spec.pvp), &(drg->u.avp_id.name), - &(drg->u.avp_id.type) )!=0) { + &(drg->u.avp_id.type) )!=0) { LM_ERR("[%s]- invalid AVP definition\n", s); + pkg_free(drg); return E_CFG; } drg->type = 1; - /* do not free the param as the AVP spec may point inside - this string*/ + /* do not free the param as the AVP spec may point inside + * this string*/ } else { while(s && *s) { if(*s<'0' || *s>'9') { - LM_ERR( "bad number\n"); + LM_ERR("bad number\n"); + pkg_free(drg); return E_UNSPEC; } drg->u.grp_id = (drg->u.grp_id)*10+(*s-'0'); diff --git a/src/modules/drouting/prefix_tree.c b/src/modules/drouting/prefix_tree.c index 7eddab600d..cfb2cb15d7 100644 --- a/src/modules/drouting/prefix_tree.c +++ b/src/modules/drouting/prefix_tree.c @@ -78,7 +78,8 @@ internal_check_rt( rt_info_wrp_t* rtlw=NULL; if((NULL==ptn) || (NULL==ptn->rg)) - goto err_exit; + return NULL; + rg_pos = ptn->rg_pos; rg=ptn->rg; for(i=0;(i<rg_pos) && (rg[i].rgid!=rgid);i++); @@ -88,15 +89,12 @@ internal_check_rt( rtlw=rg[i].rtlw; while(rtlw!=NULL) { if(check_time(rtlw->rtl->time_rec)) - goto ok_exit; + return rtlw->rtl; rtlw=rtlw->next; } } -err_exit: - return NULL; -ok_exit: - return rtlw?rtlw->rtl:0; + return NULL; } @@ -129,8 +127,6 @@ get_prefix( /* go the tree down to the last digit in the * prefix string or down to a leaf */ while(tmp< (prefix->s+prefix->len)) { - if(NULL == tmp) - goto err_exit; idx = get_node_index(*tmp); if (idx == -1){ /* unknown character in the prefix string */ @@ -147,11 +143,8 @@ get_prefix( ptree = ptree->ptnode[idx].next; tmp++; } - /* go in the tree up to the root trying to match the - * prefix */ + /* go in the tree up to the root trying to match the prefix */ while(ptree !=NULL ) { - if(NULL == tmp) - goto err_exit; /* is it a real node or an intermediate one */ idx = get_node_index(*tmp); if(idx!=-1 && NULL != ptree->ptnode[idx].rg) {
7 years, 3 months
1
0
0
0
git:master:e238567d: domainpolicy: check if set dst uri fails
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: e238567daa77f68df05cce68051792c3d7559ab7 URL:
https://github.com/kamailio/kamailio/commit/e238567daa77f68df05cce68051792c…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2017-07-27T11:11:36+02:00 domainpolicy: check if set dst uri fails --- Modified: src/modules/domainpolicy/domainpolicy.c --- Diff:
https://github.com/kamailio/kamailio/commit/e238567daa77f68df05cce68051792c…
Patch:
https://github.com/kamailio/kamailio/commit/e238567daa77f68df05cce68051792c…
--- diff --git a/src/modules/domainpolicy/domainpolicy.c b/src/modules/domainpolicy/domainpolicy.c index 003a757671..7cf7ac2d55 100644 --- a/src/modules/domainpolicy/domainpolicy.c +++ b/src/modules/domainpolicy/domainpolicy.c @@ -1018,7 +1018,10 @@ int dp_apply_policy(struct sip_msg* _msg, char* _s1, char* _s2) { duri_str.s = (char *)&(duri[0]); duri_str.len = at - duri_str.s; LM_DBG("new DURI is '%.*s'\n",duri_str.len, ZSW(duri_str.s)); - set_dst_uri(_msg, &duri_str); + if(set_dst_uri(_msg, &duri_str)<0) { + LM_ERR("failed to se dst uri\n"); + return -1; + } /* dst_uri changes, so it makes sense to re-use the current uri for forking */ ruri_mark_new(); /* re-use uri for serial forking */
7 years, 3 months
1
0
0
0
git:master:bda4f0a8: dmq_usrloc: remove useless condition
by Daniel-Constantin Mierla
Module: kamailio Branch: master Commit: bda4f0a8f8c7f65360fa73f51fb4fac289a8d334 URL:
https://github.com/kamailio/kamailio/commit/bda4f0a8f8c7f65360fa73f51fb4fac…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com> Committer: Daniel-Constantin Mierla <miconda(a)gmail.com> Date: 2017-07-27T11:10:56+02:00 dmq_usrloc: remove useless condition --- Modified: src/modules/dmq_usrloc/usrloc_sync.c --- Diff:
https://github.com/kamailio/kamailio/commit/bda4f0a8f8c7f65360fa73f51fb4fac…
Patch:
https://github.com/kamailio/kamailio/commit/bda4f0a8f8c7f65360fa73f51fb4fac…
--- diff --git a/src/modules/dmq_usrloc/usrloc_sync.c b/src/modules/dmq_usrloc/usrloc_sync.c index 9260bb28ab..de01bc2062 100644 --- a/src/modules/dmq_usrloc/usrloc_sync.c +++ b/src/modules/dmq_usrloc/usrloc_sync.c @@ -198,8 +198,6 @@ void usrloc_get_all_ucontact(dmq_node_t* node) goto done; } if (rval > 0) { - if (buf != NULL) - dmq_usrloc_free(buf); len = rval * 2; buf = dmq_usrloc_malloc(len); if (buf == NULL) {
7 years, 3 months
1
0
0
0
← Newer
1
...
11
12
13
14
15
16
17
...
41
Older →
Jump to page:
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
Results per page:
10
25
50
100
200