diff --git a/debian/patches/debian/fix_export.patch b/debian/patches/debian/fix_export.patch index 69021c7e3..7467c0b35 100644 --- a/debian/patches/debian/fix_export.patch +++ b/debian/patches/debian/fix_export.patch @@ -7,7 +7,7 @@ Subject: fix_export 1 file changed, 2 insertions(+) diff --git a/src/Makefile b/src/Makefile -index 40def34..3c8dcda 100644 +index f2fa93c..b111153 100644 --- a/src/Makefile +++ b/src/Makefile @@ -139,6 +139,8 @@ endif diff --git a/debian/patches/debian/no_INSTALL_file.patch b/debian/patches/debian/no_INSTALL_file.patch index 0ee8eacdc..c03d65ab4 100644 --- a/debian/patches/debian/no_INSTALL_file.patch +++ b/debian/patches/debian/no_INSTALL_file.patch @@ -7,7 +7,7 @@ Subject: no_INSTALL_file 1 file changed, 2 deletions(-) diff --git a/src/Makefile b/src/Makefile -index a6380c2..40def34 100644 +index b5f7192..f2fa93c 100644 --- a/src/Makefile +++ b/src/Makefile @@ -861,8 +861,6 @@ install-modules-all: install-every-module install-every-module-doc diff --git a/debian/patches/debian/no_lib64_on_64_bits.patch b/debian/patches/debian/no_lib64_on_64_bits.patch index 153565ce5..2e65ab471 100644 --- a/debian/patches/debian/no_lib64_on_64_bits.patch +++ b/debian/patches/debian/no_lib64_on_64_bits.patch @@ -7,7 +7,7 @@ Subject: no_lib64_on_64_bits 1 file changed, 1 insertion(+), 9 deletions(-) diff --git a/src/Makefile.defs b/src/Makefile.defs -index 0e49c6f..4060de2 100644 +index 5ec3536..0635767 100644 --- a/src/Makefile.defs +++ b/src/Makefile.defs @@ -454,15 +454,7 @@ endif diff --git a/debian/patches/series b/debian/patches/series index b42343a54..ec8626d2d 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -37,11 +37,10 @@ upstream/pv-headers-remove_specific_header_value.patch # collides with our changes to pua_dialoginfo sipwise/Revert-pua_dialoginfo-disable-publish-notifications-.patch ## upstream 5.6 -upstream/utils-kamcmd-add-missing-USE_READLINE-define-for-pkg.patch +# ## upstream master upstream/permissions-don-t-remove-old-data-at-the-end-of-the-.patch upstream/permissions-trusted_cleanup_interval.patch -upstream/dialog-deactivate-print-variable-function-which-is-o.patch ### relevant for upstream sipwise/pua_dialoginfo-refresh_pubruri_avps_flag.patch sipwise/pua_dialoginfo-local_identity_dlg_var.patch @@ -63,7 +62,6 @@ sipwise/kamctl-TMPDIR-config.patch sipwise/pv_headers-fix-build-warning.patch sipwise/pv_headers-use-memset.patch sipwise/pv_headers-rework-pvh_remove_header_param.patch -sipwise/usrloc-correct-AOR-value-on-usrloc-contact-expired.patch ### active development sipwise/lcr-stopper_mode-parameter.patch sipwise/presence-be-more-resilient-doing-clean-up.patch @@ -72,7 +70,6 @@ upstream/pv_headers-use-tm.t_find-API.patch upstream/tm-added-t_unset-intermodule-API-function.patch upstream/pv_headers-use-t_unset-based-on-vref-instead-of-rese.patch sipwise/pv_headers-rework-pvh_remove_header_param-take-two.patch -sipwise/pv_headers-fix-t_resume-scenario.patch # ### Don't just put stuff in any order ### use gbp pq import/export tooling to help maintain patches diff --git a/debian/patches/sipwise/Revert-pua_dialoginfo-disable-publish-notifications-.patch b/debian/patches/sipwise/Revert-pua_dialoginfo-disable-publish-notifications-.patch index 3fbf4a212..f5538bfd2 100644 --- a/debian/patches/sipwise/Revert-pua_dialoginfo-disable-publish-notifications-.patch +++ b/debian/patches/sipwise/Revert-pua_dialoginfo-disable-publish-notifications-.patch @@ -39,7 +39,7 @@ index df1e085..fd0a3fa 100644 diff --git a/src/modules/pua_dialoginfo/doc/pua_dialoginfo_admin.xml b/src/modules/pua_dialoginfo/doc/pua_dialoginfo_admin.xml -index 191ee5f..81ef722 100644 +index cfc0fc7..eebad01 100644 --- a/src/modules/pua_dialoginfo/doc/pua_dialoginfo_admin.xml +++ b/src/modules/pua_dialoginfo/doc/pua_dialoginfo_admin.xml @@ -536,71 +536,7 @@ modparam("pua_dialoginfo", "callee_trying", 1) diff --git a/debian/patches/sipwise/do-not-install-default-config.patch b/debian/patches/sipwise/do-not-install-default-config.patch index 9af453a83..e6f9e565b 100644 --- a/debian/patches/sipwise/do-not-install-default-config.patch +++ b/debian/patches/sipwise/do-not-install-default-config.patch @@ -8,7 +8,7 @@ Subject: do-not-install-default-config 2 files changed, 2 insertions(+), 2 deletions(-) diff --git a/src/Makefile b/src/Makefile -index 3c8dcda..7a8a402 100644 +index b111153..f10a178 100644 --- a/src/Makefile +++ b/src/Makefile @@ -652,7 +652,7 @@ sunpkg: diff --git a/debian/patches/sipwise/pua_dialoginfo-local_identity_dlg_var.patch b/debian/patches/sipwise/pua_dialoginfo-local_identity_dlg_var.patch index 64b7e0894..56e104b5a 100644 --- a/debian/patches/sipwise/pua_dialoginfo-local_identity_dlg_var.patch +++ b/debian/patches/sipwise/pua_dialoginfo-local_identity_dlg_var.patch @@ -8,7 +8,7 @@ Subject: pua_dialoginfo: local_identity_dlg_var 2 files changed, 37 insertions(+) diff --git a/src/modules/pua_dialoginfo/doc/pua_dialoginfo_admin.xml b/src/modules/pua_dialoginfo/doc/pua_dialoginfo_admin.xml -index 49f9f0f..81156af 100644 +index 8595b33..1de185c 100644 --- a/src/modules/pua_dialoginfo/doc/pua_dialoginfo_admin.xml +++ b/src/modules/pua_dialoginfo/doc/pua_dialoginfo_admin.xml @@ -554,6 +554,26 @@ modparam("pua_dialoginfo", "callee_trying", 1) diff --git a/debian/patches/sipwise/pua_dialoginfo-refresh_pubruri_avps_flag.patch b/debian/patches/sipwise/pua_dialoginfo-refresh_pubruri_avps_flag.patch index 6283f0a56..b20d994ff 100644 --- a/debian/patches/sipwise/pua_dialoginfo-refresh_pubruri_avps_flag.patch +++ b/debian/patches/sipwise/pua_dialoginfo-refresh_pubruri_avps_flag.patch @@ -8,7 +8,7 @@ Subject: pua_dialoginfo: refresh_pubruri_avps_flag 2 files changed, 94 insertions(+), 1 deletion(-) diff --git a/src/modules/pua_dialoginfo/doc/pua_dialoginfo_admin.xml b/src/modules/pua_dialoginfo/doc/pua_dialoginfo_admin.xml -index 81ef722..49f9f0f 100644 +index eebad01..8595b33 100644 --- a/src/modules/pua_dialoginfo/doc/pua_dialoginfo_admin.xml +++ b/src/modules/pua_dialoginfo/doc/pua_dialoginfo_admin.xml @@ -433,7 +433,25 @@ modparam("pua_dialoginfo", "use_pubruri_avps", 1) diff --git a/debian/patches/sipwise/pv_headers-fix-t_resume-scenario.patch b/debian/patches/sipwise/pv_headers-fix-t_resume-scenario.patch deleted file mode 100644 index 8ad303811..000000000 --- a/debian/patches/sipwise/pv_headers-fix-t_resume-scenario.patch +++ /dev/null @@ -1,109 +0,0 @@ -From: Victor Seva -Date: Mon, 5 Dec 2022 12:43:11 +0100 -Subject: pv_headers: fix t_resume scenario - ---- - src/modules/pv_headers/pv_headers.c | 49 +++++++++++++++++++++++++++++++++++++ - 1 file changed, 49 insertions(+) - -diff --git a/src/modules/pv_headers/pv_headers.c b/src/modules/pv_headers/pv_headers.c -index 57be587..8c7539d 100644 ---- a/src/modules/pv_headers/pv_headers.c -+++ b/src/modules/pv_headers/pv_headers.c -@@ -65,6 +65,7 @@ static void mod_destroy(void); - static int mod_init(void); - - static void handle_tm_t(tm_cell_t *t, int type, struct tmcb_params *params); -+static int handle_msg_failed_cb(struct sip_msg *msg, unsigned int flags, void *cb); - static int handle_msg_cb(struct sip_msg *msg, unsigned int flags, void *cb); - static int handle_msg_branch_cb( - struct sip_msg *msg, unsigned int flags, void *cb); -@@ -395,6 +396,12 @@ int mod_init(void) - LM_ERR("cannot register PRE_SCRIPT_CB ONREPLY_CB callbacks\n"); - return -1; - } -+ if(register_script_cb( -+ handle_msg_failed_cb, PRE_SCRIPT_CB | FAILURE_CB, 0) -+ < 0) { -+ LM_ERR("cannot register PRE_SCRIPT_CB FAILURE_CB callbacks\n"); -+ return -1; -+ } - } - - pvh_str_hash_init(&skip_headers, &skip_headers_param, "skip_headers"); -@@ -472,6 +479,29 @@ static inline char *tm_type_to_string(int type) - return "UNKNOWN"; - } - -+static inline void print_cb_flags(unsigned int flags) -+{ -+ LM_DBG("flags:"); -+ if(flags & REQUEST_CB) -+ LM_DBG("REQUEST_CB"); -+ if(flags & FAILURE_CB) -+ LM_DBG("FAILURE_CB"); -+ if(flags & ONREPLY_CB) -+ LM_DBG("ONREPLY_CB"); -+ if(flags & BRANCH_CB) -+ LM_DBG("BRANCH_CB"); -+ if(flags & ONSEND_CB) -+ LM_DBG("ONSEND_CB"); -+ if(flags & ERROR_CB) -+ LM_DBG("ERROR_CB"); -+ if(flags & LOCAL_CB) -+ LM_DBG("LOCAL_CB"); -+ if(flags & EVENT_CB) -+ LM_DBG("EVENT_CB"); -+ if(flags & BRANCH_FAILURE_CB) -+ LM_DBG("BRANCH_FAILURE_CB"); -+} -+ - void handle_tm_t(tm_cell_t *t, int type, struct tmcb_params *params) - { - struct sip_msg *msg = NULL; -@@ -501,11 +531,25 @@ void handle_tm_t(tm_cell_t *t, int type, struct tmcb_params *params) - return; - } - -+int handle_msg_failed_cb(struct sip_msg *msg, unsigned int flags, void *cb) -+{ -+ print_cb_flags(flags); -+ -+ if(pvh_parse_msg(msg) != 0) -+ return 1; -+ -+ _branch = 0; -+ LM_DBG("msg:%p set branch:%d\n", msg, _branch); -+ return 1; -+} -+ - static int msg_cbs = - TMCB_REQUEST_FWDED | TMCB_RESPONSE_FWDED | TMCB_ON_BRANCH_FAILURE; - - int handle_msg_cb(struct sip_msg *msg, unsigned int flags, void *cb) - { -+ print_cb_flags(flags); -+ - if(pvh_parse_msg(msg) != 0) - return 1; - -@@ -524,6 +568,7 @@ int handle_msg_branch_cb(struct sip_msg *msg, unsigned int flags, void *cb) - { - - LM_DBG("msg:%p previous branch:%d\n", msg, _branch); -+ print_cb_flags(flags); - - if(flags & PRE_SCRIPT_CB) { - pvh_get_branch_index(msg, &_branch); -@@ -543,7 +588,11 @@ int handle_msg_reply_cb(struct sip_msg *msg, unsigned int flags, void *cb) - - if(pvh_parse_msg(msg) != 0) - return 1; -+ if(msg == FAKED_REPLY) { -+ LM_DBG("FAKED_REPLY\n"); -+ } - LM_DBG("msg:%p previous branch:%d\n", msg, _branch); -+ print_cb_flags(flags); - - t = tmb.t_find(msg, &_branch, &vref); - if(t != NULL && t != T_UNDEFINED) { diff --git a/debian/patches/sipwise/pv_headers-rework-pvh_remove_header_param-take-two.patch b/debian/patches/sipwise/pv_headers-rework-pvh_remove_header_param-take-two.patch index 029f6fad2..f50782089 100644 --- a/debian/patches/sipwise/pv_headers-rework-pvh_remove_header_param-take-two.patch +++ b/debian/patches/sipwise/pv_headers-rework-pvh_remove_header_param-take-two.patch @@ -12,10 +12,10 @@ Subject: pv_headers: rework pvh_remove_header_param, take two 4 files changed, 38 insertions(+), 28 deletions(-) diff --git a/src/modules/pv_headers/pv_headers.c b/src/modules/pv_headers/pv_headers.c -index 8a2976e..57be587 100644 +index 0bb710e..8c7539d 100644 --- a/src/modules/pv_headers/pv_headers.c +++ b/src/modules/pv_headers/pv_headers.c -@@ -222,12 +222,15 @@ static int w_pvh_header_param_exists( +@@ -223,12 +223,15 @@ static int w_pvh_header_param_exists( static int ki_pvh_remove_header_param(struct sip_msg *msg, str *hname, str *toRemove) { @@ -33,7 +33,7 @@ index 8a2976e..57be587 100644 if (avi->val.type == SR_XTYPE_STR && avi->val.v.s.s != NULL) { if(str_casesearch(&avi->val.v.s, toRemove) != NULL) { new_size = pvh_remove_header_param_helper(&avi->val.v.s, toRemove, &dst); -@@ -236,13 +239,17 @@ static int ki_pvh_remove_header_param(struct sip_msg *msg, str *hname, str *toRe +@@ -237,13 +240,17 @@ static int ki_pvh_remove_header_param(struct sip_msg *msg, str *hname, str *toRe STR_FMT(hname), idx); if(pvh_remove_header(msg, hname, idx) < 0) return -1; @@ -52,7 +52,7 @@ index 8a2976e..57be587 100644 LM_ERR("can't set new value\n"); return -1; } -@@ -252,7 +259,10 @@ static int ki_pvh_remove_header_param(struct sip_msg *msg, str *hname, str *toRe +@@ -253,7 +260,10 @@ static int ki_pvh_remove_header_param(struct sip_msg *msg, str *hname, str *toRe STR_FMT(&avi->val.v.s)); } } diff --git a/debian/patches/sipwise/pv_headers-rework-pvh_remove_header_param.patch b/debian/patches/sipwise/pv_headers-rework-pvh_remove_header_param.patch index 4dec0a092..4953638a1 100644 --- a/debian/patches/sipwise/pv_headers-rework-pvh_remove_header_param.patch +++ b/debian/patches/sipwise/pv_headers-rework-pvh_remove_header_param.patch @@ -13,10 +13,10 @@ Subject: pv_headers: rework pvh_remove_header_param 3 files changed, 75 insertions(+), 81 deletions(-) diff --git a/src/modules/pv_headers/pv_headers.c b/src/modules/pv_headers/pv_headers.c -index be43bb2..9658ed7 100644 +index 5b2c0ee..73acd08 100644 --- a/src/modules/pv_headers/pv_headers.c +++ b/src/modules/pv_headers/pv_headers.c -@@ -220,15 +220,47 @@ static int w_pvh_header_param_exists( +@@ -221,15 +221,47 @@ static int w_pvh_header_param_exists( return pvh_header_param_exists(msg, &hname, &value); } @@ -69,7 +69,7 @@ index be43bb2..9658ed7 100644 if(fixup_get_svalue(msg, (gparam_p)p1, &hname) < 0) return -1; -@@ -236,20 +268,7 @@ static int w_pvh_remove_header_param(struct sip_msg *msg, char *p1, char *p2) +@@ -237,20 +269,7 @@ static int w_pvh_remove_header_param(struct sip_msg *msg, char *p1, char *p2) if(p2 && fixup_get_svalue(msg, (gparam_p)p2, &value) < 0) return -1; @@ -91,7 +91,7 @@ index be43bb2..9658ed7 100644 } /* clang-format off */ -@@ -594,8 +613,8 @@ static sr_kemi_t pvh_kemi_exports[] = { +@@ -643,8 +662,8 @@ static sr_kemi_t pvh_kemi_exports[] = { SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE} }, { str_init("pv_headers"), str_init("pvh_remove_header_param"), diff --git a/debian/patches/sipwise/usrloc-correct-AOR-value-on-usrloc-contact-expired.patch b/debian/patches/sipwise/usrloc-correct-AOR-value-on-usrloc-contact-expired.patch deleted file mode 100644 index eb3d28089..000000000 --- a/debian/patches/sipwise/usrloc-correct-AOR-value-on-usrloc-contact-expired.patch +++ /dev/null @@ -1,97 +0,0 @@ -From: Victor Seva -Date: Thu, 9 Feb 2023 11:45:29 +0100 -Subject: usrloc: correct AOR value on usrloc:contact-expired - -previously $ulc(x=>aor) had only the user part even with use_domain set ---- - src/modules/usrloc/udomain.c | 39 +++++++++++++++++++++++++++++++-------- - 1 file changed, 31 insertions(+), 8 deletions(-) - -diff --git a/src/modules/usrloc/udomain.c b/src/modules/usrloc/udomain.c -index 204ddfd..534583e 100644 ---- a/src/modules/usrloc/udomain.c -+++ b/src/modules/usrloc/udomain.c -@@ -905,7 +905,7 @@ int udomain_contact_expired_cb(db1_con_t* _c, udomain_t* _d) - db_val_t query_vals[3]; - int key_num = 2; - db1_res_t* res = NULL; -- str user, contact; -+ str user, contact, domain; - int i; - int n; - urecord_t r; -@@ -913,6 +913,9 @@ int udomain_contact_expired_cb(db1_con_t* _c, udomain_t* _d) - #define RUIDBUF_SIZE 128 - char ruidbuf[RUIDBUF_SIZE]; - str ruid; -+#define AORBUF_SIZE 512 -+ char aorbuf[AORBUF_SIZE]; -+ str aor; - - if (ul_db_mode!=DB_ONLY) { - return 0; -@@ -1007,6 +1010,14 @@ int udomain_contact_expired_cb(db1_con_t* _c, udomain_t* _d) - continue; - } - user.len = strlen(user.s); -+ if(user.len < AORBUF_SIZE ) { -+ memcpy(aorbuf, user.s, user.len); -+ aor.s = aorbuf; -+ aor.len = user.len; -+ } else { -+ LM_ERR("user is too long %d\n", user.len); -+ continue; -+ } - - ci = dbrow2info(ROW_VALUES(row)+1, &contact, 0); - if (ci==0) { -@@ -1015,18 +1026,30 @@ int udomain_contact_expired_cb(db1_con_t* _c, udomain_t* _d) - continue; - } - -- lock_udomain(_d, &user); -+ if(ul_use_domain) { -+ domain.s = (char*)VAL_STRING(ROW_VALUES(row)+20); -+ domain.len = strlen(domain.s); -+ if(domain.len + aor.len < AORBUF_SIZE) { -+ aorbuf[aor.len] = '@'; -+ memcpy(aorbuf+aor.len+1, domain.s, domain.len); -+ aor.len += domain.len + 1; -+ } else { -+ LM_ERR("aor too long, using user part only\n"); -+ } -+ } -+ -+ lock_udomain(_d, &aor); - /* don't use the same static value from get_static_urecord() */ - memset( &r, 0, sizeof(struct urecord) ); -- r.aor = user; -- r.aorhash = ul_get_aorhash(&user); -+ r.aor = aor; -+ r.aorhash = ul_get_aorhash(&aor); - r.domain = _d->name; - - if ( (c=mem_insert_ucontact(&r, &contact, ci)) == 0) { - LM_ERR("inserting temporary contact failed for %.*s\n", -- user.len, user.s); -+ aor.len, aor.s); - release_urecord(&r); -- unlock_udomain(_d, &user); -+ unlock_udomain(_d, &aor); - goto error; - } - -@@ -1045,11 +1068,11 @@ int udomain_contact_expired_cb(db1_con_t* _c, udomain_t* _d) - ruid.len = c->ruid.len; - } else { - LM_ERR("ruid is too long %d for %.*s\n", c->ruid.len, -- user.len, user.s); -+ aor.len, aor.s); - } - } - release_urecord(&r); -- unlock_udomain(_d, &user); -+ unlock_udomain(_d, &aor); - if(ruid.len > 0 && ul_xavp_contact_name.s != NULL) { - /* delete attributes by ruid */ - uldb_delete_attrs_ruid(_d->name, &ruid); diff --git a/debian/patches/sipwise/usrloc_dbro.patch b/debian/patches/sipwise/usrloc_dbro.patch index 4aca4353f..4c94b9ad4 100644 --- a/debian/patches/sipwise/usrloc_dbro.patch +++ b/debian/patches/sipwise/usrloc_dbro.patch @@ -8,7 +8,7 @@ Subject: usrloc_dbro 2 files changed, 67 insertions(+) diff --git a/src/modules/usrloc/usrloc_mod.c b/src/modules/usrloc/usrloc_mod.c -index db8bfbe..729fb6a7 100644 +index 2953f88..5a8d4d1 100644 --- a/src/modules/usrloc/usrloc_mod.c +++ b/src/modules/usrloc/usrloc_mod.c @@ -167,6 +167,7 @@ str ulattrs_avalue_col = str_init(ULATTRS_AVALUE_COL); /*!< Name of column conta diff --git a/debian/patches/upstream/dialog-deactivate-print-variable-function-which-is-o.patch b/debian/patches/upstream/dialog-deactivate-print-variable-function-which-is-o.patch deleted file mode 100644 index e38159d3b..000000000 --- a/debian/patches/upstream/dialog-deactivate-print-variable-function-which-is-o.patch +++ /dev/null @@ -1,85 +0,0 @@ -From: Henning Westerholt -Date: Wed, 16 Nov 2022 15:33:06 +0000 -Subject: dialog: deactivate print variable function which is only used for - debugging - -- deactivate print variable function which is only used for debugging -- this function is not good for performance and might also cause race - conditions ---- - src/modules/dialog/dialog.c | 3 +++ - src/modules/dialog/dlg_var.c | 12 +++++++++--- - src/modules/dialog/dlg_var.h | 2 ++ - 3 files changed, 14 insertions(+), 3 deletions(-) - -diff --git a/src/modules/dialog/dialog.c b/src/modules/dialog/dialog.c -index 243bb9b..9823877 100644 ---- a/src/modules/dialog/dialog.c -+++ b/src/modules/dialog/dialog.c -@@ -140,6 +140,8 @@ stat_var *expired_dlgs = 0; - stat_var *failed_dlgs = 0; - stat_var *early_dlgs = 0; - -+int debug_variables_list = 0; -+ - struct tm_binds d_tmb; - struct rr_binds d_rrb; - pv_spec_t timeout_avp; -@@ -327,6 +329,7 @@ static param_export_t mod_params[]={ - { "h_id_start", PARAM_INT, &dlg_h_id_start }, - { "h_id_step", PARAM_INT, &dlg_h_id_step }, - { "keep_proxy_rr", INT_PARAM, &dlg_keep_proxy_rr }, -+ { "debug_variables", PARAM_INT, &debug_variables_list }, - { 0,0,0 } - }; - -diff --git a/src/modules/dialog/dlg_var.c b/src/modules/dialog/dlg_var.c -index b2a373a..311b3c0 100644 ---- a/src/modules/dialog/dlg_var.c -+++ b/src/modules/dialog/dlg_var.c -@@ -317,7 +317,9 @@ int set_dlg_variable(struct dlg_cell *dlg, str *key, str *val) - if ( dlg_db_mode==DB_MODE_REALTIME ) - update_dialog_dbinfo(dlg); - -- print_lists(dlg); -+ if(unlikely(debug_variables_list)) { -+ print_lists(dlg); -+ } - - return 0; - -@@ -366,7 +368,9 @@ int pv_get_dlg_variable(struct sip_msg *msg, pv_param_t *param, pv_value_t *res) - } - } - -- print_lists(dlg); -+ if(unlikely(debug_variables_list)) { -+ print_lists(dlg); -+ } - - /* unlock dialog */ - if (dlg) { -@@ -440,7 +444,9 @@ int pv_set_dlg_variable(struct sip_msg* msg, pv_param_t *param, int op, pv_value - } - dlg_unlock(d_table, &(d_table->entries[dlg->h_entry])); - } -- print_lists(dlg); -+ if(unlikely(debug_variables_list)) { -+ print_lists(dlg); -+ } - - dlg_release(dlg); - return 0; -diff --git a/src/modules/dialog/dlg_var.h b/src/modules/dialog/dlg_var.h -index f13fa45..dc7698d 100644 ---- a/src/modules/dialog/dlg_var.h -+++ b/src/modules/dialog/dlg_var.h -@@ -83,6 +83,8 @@ extern stat_var *processed_dlgs; /*!< number of processed dialogs */ - extern stat_var *expired_dlgs; /*!< number of expired dialogs */ - extern stat_var *failed_dlgs; /*!< number of failed dialogs */ - -+extern int debug_variables_list; -+ - int pv_get_dlg_ctx(sip_msg_t *msg, pv_param_t *param, - pv_value_t *res); - int pv_set_dlg_ctx(sip_msg_t *msg, pv_param_t *param, diff --git a/debian/patches/upstream/pv-headers-remove_specific_header_value.patch b/debian/patches/upstream/pv-headers-remove_specific_header_value.patch index 521e60404..a6ee06c06 100644 --- a/debian/patches/upstream/pv-headers-remove_specific_header_value.patch +++ b/debian/patches/upstream/pv-headers-remove_specific_header_value.patch @@ -84,10 +84,10 @@ index a5211b9..47d40e1 100644 2018 diff --git a/src/modules/pv_headers/pv_headers.c b/src/modules/pv_headers/pv_headers.c -index 6dfac3d..be43bb2 100644 +index daf223c..5b2c0ee 100644 --- a/src/modules/pv_headers/pv_headers.c +++ b/src/modules/pv_headers/pv_headers.c -@@ -205,6 +205,53 @@ static int w_pvh_remove_header( +@@ -206,6 +206,53 @@ static int w_pvh_remove_header( return pvh_remove_header(msg, &hname, indx); } @@ -141,7 +141,7 @@ index 6dfac3d..be43bb2 100644 /* clang-format off */ static cmd_export_t cmds[] = { {"pvh_collect_headers", (cmd_function)w_pvh_collect_headers, 0, 0, 0, -@@ -225,6 +272,10 @@ static cmd_export_t cmds[] = { +@@ -226,6 +273,10 @@ static cmd_export_t cmds[] = { fixup_spve_null, fixup_free_spve_null, ANY_ROUTE}, {"pvh_remove_header", (cmd_function)w_pvh_remove_header, 2, fixup_spve_spve, fixup_free_spve_spve, ANY_ROUTE}, @@ -152,7 +152,7 @@ index 6dfac3d..be43bb2 100644 {0, 0, 0, 0, 0, 0} }; -@@ -537,6 +588,16 @@ static sr_kemi_t pvh_kemi_exports[] = { +@@ -586,6 +637,16 @@ static sr_kemi_t pvh_kemi_exports[] = { { SR_KEMIP_STR, SR_KEMIP_INT, SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE, SR_KEMIP_NONE} }, diff --git a/debian/patches/upstream/pv_headers-use-t_unset-based-on-vref-instead-of-rese.patch b/debian/patches/upstream/pv_headers-use-t_unset-based-on-vref-instead-of-rese.patch index acee02d8d..2117a7766 100644 --- a/debian/patches/upstream/pv_headers-use-t_unset-based-on-vref-instead-of-rese.patch +++ b/debian/patches/upstream/pv_headers-use-t_unset-based-on-vref-instead-of-rese.patch @@ -8,10 +8,10 @@ Subject: [PATCH] pv_headers: use t_unset() based on vref instead of resetting 1 file changed, 4 insertions(+), 4 deletions(-) diff --git a/src/modules/pv_headers/pv_headers.c b/src/modules/pv_headers/pv_headers.c -index f547f2d..8a2976e 100644 +index 64460a3..0bb710e 100644 --- a/src/modules/pv_headers/pv_headers.c +++ b/src/modules/pv_headers/pv_headers.c -@@ -555,12 +555,12 @@ int handle_msg_reply_cb(struct sip_msg *msg, unsigned int flags, void *cb) +@@ -604,12 +604,12 @@ int handle_msg_reply_cb(struct sip_msg *msg, unsigned int flags, void *cb) xavi_set_list(backup_xavis); LM_DBG("restored backup_xavis:%p\n", *backup_xavis); } diff --git a/debian/patches/upstream/pv_headers-use-tm.t_find-API.patch b/debian/patches/upstream/pv_headers-use-tm.t_find-API.patch index 9a785ca7e..dd503b942 100644 --- a/debian/patches/upstream/pv_headers-use-tm.t_find-API.patch +++ b/debian/patches/upstream/pv_headers-use-tm.t_find-API.patch @@ -7,10 +7,10 @@ Subject: [PATCH] pv_headers: use tm.t_find API 1 file changed, 8 insertions(+), 13 deletions(-) diff --git a/src/modules/pv_headers/pv_headers.c b/src/modules/pv_headers/pv_headers.c -index 9658ed7..f547f2d 100644 +index 73acd08..64460a3 100644 --- a/src/modules/pv_headers/pv_headers.c +++ b/src/modules/pv_headers/pv_headers.c -@@ -526,6 +526,7 @@ int handle_msg_branch_cb(struct sip_msg *msg, unsigned int flags, void *cb) +@@ -571,6 +571,7 @@ int handle_msg_branch_cb(struct sip_msg *msg, unsigned int flags, void *cb) int handle_msg_reply_cb(struct sip_msg *msg, unsigned int flags, void *cb) { @@ -18,9 +18,9 @@ index 9658ed7..f547f2d 100644 tm_cell_t *t = NULL; sr_xavp_t **backup_xavis = NULL; sr_xavp_t **list = NULL; -@@ -534,18 +535,12 @@ int handle_msg_reply_cb(struct sip_msg *msg, unsigned int flags, void *cb) - return 1; +@@ -583,18 +584,12 @@ int handle_msg_reply_cb(struct sip_msg *msg, unsigned int flags, void *cb) LM_DBG("msg:%p previous branch:%d\n", msg, _branch); + print_cb_flags(flags); - if(tmb.t_check(msg, &_branch) == -1) { - LM_ERR("failed find UAC branch\n"); @@ -43,7 +43,7 @@ index 9658ed7..f547f2d 100644 } pvh_get_branch_index(msg, &_branch); -@@ -560,7 +555,7 @@ int handle_msg_reply_cb(struct sip_msg *msg, unsigned int flags, void *cb) +@@ -609,7 +604,7 @@ int handle_msg_reply_cb(struct sip_msg *msg, unsigned int flags, void *cb) xavi_set_list(backup_xavis); LM_DBG("restored backup_xavis:%p\n", *backup_xavis); } diff --git a/debian/patches/upstream/tm-added-t_unset-intermodule-API-function.patch b/debian/patches/upstream/tm-added-t_unset-intermodule-API-function.patch index 1ef811772..1203457c4 100644 --- a/debian/patches/upstream/tm-added-t_unset-intermodule-API-function.patch +++ b/debian/patches/upstream/tm-added-t_unset-intermodule-API-function.patch @@ -13,7 +13,7 @@ Subject: [PATCH] tm: added t_unset() intermodule API function 4 files changed, 18 insertions(+) diff --git a/src/modules/tm/t_lookup.c b/src/modules/tm/t_lookup.c -index 9b21e98..8618894 100644 +index 977cc0a..4b4073e 100644 --- a/src/modules/tm/t_lookup.c +++ b/src/modules/tm/t_lookup.c @@ -167,6 +167,19 @@ struct cell* t_find(struct sip_msg *msg, int *branch, int *vref) diff --git a/debian/patches/upstream/tm-new-inter-module-API-function-t_find.patch b/debian/patches/upstream/tm-new-inter-module-API-function-t_find.patch index db8b29539..f54cde99b 100644 --- a/debian/patches/upstream/tm-new-inter-module-API-function-t_find.patch +++ b/debian/patches/upstream/tm-new-inter-module-API-function-t_find.patch @@ -12,7 +12,7 @@ Subject: [PATCH] tm: new inter-module API function t_find(...) 4 files changed, 27 insertions(+) diff --git a/src/modules/tm/t_lookup.c b/src/modules/tm/t_lookup.c -index 4ccdee7..9b21e98 100644 +index 9b5e85a..977cc0a 100644 --- a/src/modules/tm/t_lookup.c +++ b/src/modules/tm/t_lookup.c @@ -145,6 +145,28 @@ int get_t_branch() diff --git a/debian/patches/upstream/utils-kamcmd-add-missing-USE_READLINE-define-for-pkg.patch b/debian/patches/upstream/utils-kamcmd-add-missing-USE_READLINE-define-for-pkg.patch deleted file mode 100644 index b313772bc..000000000 --- a/debian/patches/upstream/utils-kamcmd-add-missing-USE_READLINE-define-for-pkg.patch +++ /dev/null @@ -1,22 +0,0 @@ -From: Henning Westerholt -Date: Wed, 14 Dec 2022 08:38:12 +0000 -Subject: [PATCH] utils/kamcmd: add missing USE_READLINE define for pkg-config - build, related to #3284 - -(cherry picked from commit a70b6bf09c73d961ebea1947216757fafb951c24) ---- - utils/kamcmd/Makefile | 1 + - 1 file changed, 1 insertion(+) - -diff --git a/utils/kamcmd/Makefile b/utils/kamcmd/Makefile -index f12306b..1fd923d 100644 ---- a/utils/kamcmd/Makefile -+++ b/utils/kamcmd/Makefile -@@ -80,6 +80,7 @@ endif - # detect libreadline - ifneq ($(BUILDER),) - DEFS += $(shell $(BUILDER) --cflags readline) -+ DEFS+=-DUSE_READLINE - LIBS += $(shell $(BUILDER) --libs readline) - use_readline := 1 - else