|
@@ -457,19 +457,23 @@ void delete_subs(str* pres_uri, str* ev_name, str* to_tag,
|
|
str* from_tag, str* callid)
|
|
str* from_tag, str* callid)
|
|
{
|
|
{
|
|
subs_t subs;
|
|
subs_t subs;
|
|
|
|
+
|
|
memset(&subs, 0, sizeof(subs_t));
|
|
memset(&subs, 0, sizeof(subs_t));
|
|
-
|
|
|
|
subs.pres_uri = *pres_uri;
|
|
subs.pres_uri = *pres_uri;
|
|
subs.from_tag = *from_tag;
|
|
subs.from_tag = *from_tag;
|
|
subs.to_tag = *to_tag;
|
|
subs.to_tag = *to_tag;
|
|
subs.callid = *callid;
|
|
subs.callid = *callid;
|
|
-
|
|
|
|
|
|
+
|
|
/* delete record from hash table also if not in dbonly mode */
|
|
/* delete record from hash table also if not in dbonly mode */
|
|
if(subs_dbmode != DB_ONLY)
|
|
if(subs_dbmode != DB_ONLY)
|
|
{
|
|
{
|
|
unsigned int hash_code= core_hash(pres_uri, ev_name, shtable_size);
|
|
unsigned int hash_code= core_hash(pres_uri, ev_name, shtable_size);
|
|
- if(delete_shtable(subs_htable, hash_code, &subs) < 0)
|
|
|
|
- LM_ERR("Failed to delete subscription from memory\n");
|
|
|
|
|
|
+ if(delete_shtable(subs_htable, hash_code, &subs) < 0) {
|
|
|
|
+ LM_ERR("Failed to delete subscription from memory"
|
|
|
|
+ " [%.*s : %.*s / %.*s / %.*s]\n", ev_name->len, ev_name->s,
|
|
|
|
+ callid->len, callid->s, from_tag->len, from_tag->s,
|
|
|
|
+ to_tag->len, to_tag->s);
|
|
|
|
+ }
|
|
}
|
|
}
|
|
|
|
|
|
if(subs_dbmode != NO_DB && delete_db_subs(to_tag, from_tag, callid)< 0)
|
|
if(subs_dbmode != NO_DB && delete_db_subs(to_tag, from_tag, callid)< 0)
|