Module: kamailio
Branch: master
Commit: 1d83950eb3f0eba21b2ade1d1c5565b1ef95c1d1
URL:
https://github.com/kamailio/kamailio/commit/1d83950eb3f0eba21b2ade1d1c5565b…
Author: Daniel-Constantin Mierla <miconda(a)gmail.com>
Committer: Daniel-Constantin Mierla <miconda(a)gmail.com>
Date: 2024-11-20T17:41:22+01:00
pipelimit: 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/pipelimit/pipelimit.c
---
Diff:
https://github.com/kamailio/kamailio/commit/1d83950eb3f0eba21b2ade1d1c5565b…
Patch:
https://github.com/kamailio/kamailio/commit/1d83950eb3f0eba21b2ade1d1c5565b…
---
diff --git a/src/modules/pipelimit/pipelimit.c b/src/modules/pipelimit/pipelimit.c
index 27b247e49c3..a632a4cda51 100644
--- a/src/modules/pipelimit/pipelimit.c
+++ b/src/modules/pipelimit/pipelimit.c
@@ -433,45 +433,7 @@ static int mod_init(void)
static void destroy(void)
{
- pl_destroy_htable();
-
- if(network_load_value) {
- shm_free(network_load_value);
- network_load_value = NULL;
- }
- if(load_value) {
- shm_free(load_value);
- load_value = NULL;
- }
- if(load_source) {
- shm_free(load_source);
- load_source = NULL;
- }
- if(pid_kp) {
- shm_free(pid_kp);
- pid_kp = NULL;
- }
- if(pid_ki) {
- shm_free(pid_ki);
- pid_ki = NULL;
- }
- if(pid_kd) {
- shm_free(pid_kd);
- pid_kd = NULL;
- }
- if(_pl_pid_setpoint) {
- shm_free(_pl_pid_setpoint);
- _pl_pid_setpoint = NULL;
- }
- if(drop_rate) {
- shm_free(drop_rate);
- drop_rate = NULL;
- }
-
- if(pl_timer) {
- timer_free(pl_timer);
- pl_timer = NULL;
- }
+ LM_DBG("done");
}