Module: kamailio
Branch: master
Commit: 4347f1470057ba8a3c7cf8f179a814163c38d34e
URL: https://github.com/kamailio/kamailio/commit/4347f1470057ba8a3c7cf8f179a8141…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2024-11-20T12:08:54+01:00
pua: remove destroy of internal structures on mod-destroy callback
- it is safer and faster to be removed at once by core or OS when application
context is destroyed
---
Modified: src/modules/pua/pua.c
---
Diff: https://github.com/kamailio/kamailio/commit/4347f1470057ba8a3c7cf8f179a8141…
Patch: https://github.com/kamailio/kamailio/commit/4347f1470057ba8a3c7cf8f179a8141…
---
diff --git a/src/modules/pua/pua.c b/src/modules/pua/pua.c
index 9b174dcdb6e..515abe0dc4c 100644
--- a/src/modules/pua/pua.c
+++ b/src/modules/pua/pua.c
@@ -296,21 +296,13 @@ static int child_init(int rank)
static void destroy(void)
{
- if(puacb_list)
- destroy_puacb_list();
-
/* if dbmode is PUA_DB_ONLY, then HashT will be NULL
* so db_update and destroy_htable won't get called */
if(pua_db && HashT)
db_update(0, 0);
- if(HashT)
- destroy_htable();
-
if(pua_db)
pua_dbf.close(pua_db);
- if(pua_evlist)
- destroy_pua_evlist();
return;
}