diff --git a/debian/patches/series b/debian/patches/series index b8afd2bc3..4a3864dc0 100644 --- a/debian/patches/series +++ b/debian/patches/series @@ -42,6 +42,7 @@ upstream/dialog-dlg_get_var-assure-return-null-on-error.patch upstream/dialog-w_dlg_get_var-fix-incompatible-pointer.patch upstream/topos-skip-adding-contact-header-for-BYE-CANCEL-PRAC.patch upstream/presence-No-autocommit-rollback-if-no-active-watcher.patch +upstream/topos_redis_use_tag_based_on_direction_for_early_dialog_transaction_record_loading.patch ### relevant for upstream sipwise/core-fix-freeaddrinfo-coredump.patch sipwise/pua_dialoginfo-refresh_pubruri_avps_flag.patch diff --git a/debian/patches/upstream/topos_redis_use_tag_based_on_direction_for_early_dialog_transaction_record_loading.patch b/debian/patches/upstream/topos_redis_use_tag_based_on_direction_for_early_dialog_transaction_record_loading.patch new file mode 100644 index 000000000..e3c381609 --- /dev/null +++ b/debian/patches/upstream/topos_redis_use_tag_based_on_direction_for_early_dialog_transaction_record_loading.patch @@ -0,0 +1,43 @@ +--- a/src/modules/topos_redis/topos_redis_storage.c ++++ b/src/modules/topos_redis/topos_redis_storage.c +@@ -54,6 +54,10 @@ static str _tps_redis_dprefix = str_init + + static char _tps_redis_cbuf[TPS_REDIS_DATA_SIZE]; + ++static str _tps_redis_empty = str_init(""); ++ ++#define TPS_REDIS_STRZ(_s) ((_s).s)?(_s):(_tps_redis_empty) ++ + /** + * storage keys + */ +@@ -594,6 +598,7 @@ int tps_redis_load_initial_method_branch + str skey = STR_NULL; + str sval = STR_NULL; + str xuuid = str_init(""); ++ str xtag = str_init(""); + str smethod = str_init("INVITE"); + + if(msg==NULL || md==NULL || sd==NULL) +@@ -615,6 +620,12 @@ int tps_redis_load_initial_method_branch + memset(argvlen, 0, TPS_REDIS_NR_KEYS * sizeof(size_t)); + argc = 0; + ++ if(md->direction==TPS_DIR_DOWNSTREAM) { ++ xtag = TPS_REDIS_STRZ(md->b_tag); ++ } else { ++ xtag = TPS_REDIS_STRZ(md->a_tag); ++ } ++ + if(md->a_uuid.len>1) { + xuuid.s = md->a_uuid.s + 1; + xuuid.len = md->a_uuid.len - 1; +@@ -641,7 +652,7 @@ int tps_redis_load_initial_method_branch + _tps_redis_bprefix.len, _tps_redis_bprefix.s, + smethod.len, smethod.s, + md->a_callid.len, md->a_callid.s, +- md->b_tag.len, md->b_tag.s, ++ xtag.len, xtag.s, + xuuid.len, xuuid.s); + if(rkey.len<0 || rkey.len>=TPS_REDIS_DATA_SIZE) { + LM_ERR("error or insufficient buffer size: %d\n", rkey.len);