general: add memory auditing

memory_utils: added to wrap memory alloc / free
general: adjusted stabdard and other memory allocs t be audited
This commit is contained in:
Ian-Clowes 2020-08-03 04:01:58 +01:00 committed by Polynomialdivision
parent 421324486f
commit d56c5c4e15
14 changed files with 355 additions and 93 deletions

View file

@ -4,6 +4,7 @@
#include <stdlib.h>
#include <unistd.h>
#include "memory_utils.h"
#include "datastorage.h"
#include "networksocket.h"
#include "ubus.h"
@ -30,7 +31,8 @@ void daemon_shutdown() {
void signal_handler(int sig) {
switch (sig) {
case SIGHUP:
daemon_shutdown();
//daemon_shutdown();
dawn_memory_audit();
break;
case SIGINT:
daemon_shutdown();