diff --git a/src/core/lib/utils/memory.c b/src/core/lib/utils/memory.c index e58f558..7cca62e 100644 --- a/src/core/lib/utils/memory.c +++ b/src/core/lib/utils/memory.c @@ -7,9 +7,7 @@ #include #include -#include - -#include +#include //LOCAL typedef struct node @@ -107,6 +105,15 @@ void *why2_realloc(void *pointer, unsigned long size) return allocated; } +char *why2_strdup(char *string) +{ + char *allocated = strdup(string); + + push_to_list(allocated); + + return allocated; +} + void why2_free(void *pointer) { //VARIABLES