diff --git a/src/list.c b/src/list.c index c17c700..bb83506 100644 --- a/src/list.c +++ b/src/list.c @@ -24,9 +24,10 @@ void set_ll_free_all(struct SETBlockMeta *head) struct SETBlockMeta *set_ll_free_one(struct SETBlockMeta *head, void *address) { - struct SETBlockMeta *meta = - (struct SETBlockMeta *)address - (sizeof(struct SETBlockMeta)); + (struct SETBlockMeta *)(address - (sizeof(struct SETBlockMeta))); + + printf("Freeing: %p\n", meta); if (meta->prev == NULL) { diff --git a/src/utils.c b/src/utils.c index 4f88b84..391eb62 100644 --- a/src/utils.c +++ b/src/utils.c @@ -64,6 +64,8 @@ void *set_malloc(size_t n) block_meta_head->end = meta; } + printf("Allocating at address %p\n", blocks); + return blocks + sizeof(struct SETBlockMeta); }