MEMORY add wrappers around all mallocs and frees and trace them

This patch adds a wrapper around all memory allocations and frees.
The idea is to get warned immediately if the application leaks memory.
Additionally the wrapper functions make it easy to add different
memory allocators or memory pools in the future.
This commit is contained in:
Peter Lieven
2012-11-03 01:05:57 +01:00
parent 389f6a8ba5
commit d327ab09c6
11 changed files with 300 additions and 287 deletions

View File

@@ -77,6 +77,7 @@ struct iscsi_url {
char user[MAX_STRING_SIZE+1];
char passwd[MAX_STRING_SIZE+1];
int lun;
struct iscsi_context *iscsi;
};
/*