Module: kamailio
Branch: master
Commit: 2c540b67a8a3f15835583926bfdef7cf6b71b4bf
URL:
https://github.com/kamailio/kamailio/commit/2c540b67a8a3f15835583926bfdef7c…
Author: Henning Westerholt <hw(a)gilawa.com>
Committer: Henning Westerholt <hw(a)gilawa.com>
Date: 2023-03-29T13:44:44Z
Revert "pike: use pkg_malloc/pkg_free instead of system malloc"
This reverts commit 6492a6f905075fa73d911c345fe784f2d3c085e5.
---
Modified: src/modules/pike/pike_top.c
---
Diff:
https://github.com/kamailio/kamailio/commit/2c540b67a8a3f15835583926bfdef7c…
Patch:
https://github.com/kamailio/kamailio/commit/2c540b67a8a3f15835583926bfdef7c…
---
diff --git a/src/modules/pike/pike_top.c b/src/modules/pike/pike_top.c
index c7894604b6..6940e84ca6 100644
--- a/src/modules/pike/pike_top.c
+++ b/src/modules/pike/pike_top.c
@@ -79,10 +79,10 @@ int pike_top_add_entry( unsigned char *ip_addr, int addr_len,
unsigned int expires, pike_node_status_t status )
{
struct TopListItem_t *new_item
- = (struct TopListItem_t *)pkg_malloc(sizeof(struct TopListItem_t));
+ = (struct TopListItem_t *)malloc(sizeof(struct TopListItem_t));
if(!new_item)
{
- PKG_MEM_ERROR;
+ SYS_MEM_ERROR;
return -1;
}
print_addr(ip_addr, addr_len);
@@ -119,7 +119,7 @@ void pike_top_list_clear()
top_list_iter = top_list_root;
while (top_list_iter) {
ptr = top_list_iter->next;
- pkg_free(top_list_iter);
+ free(top_list_iter);
top_list_iter = ptr;
}
top_list_root = 0;