diff options
Diffstat (limited to 'set_linked_lists.c')
-rw-r--r-- | set_linked_lists.c | 3 |
1 files changed, 3 insertions, 0 deletions
diff --git a/set_linked_lists.c b/set_linked_lists.c index 8cc77c4..ee0a021 100644 --- a/set_linked_lists.c +++ b/set_linked_lists.c @@ -9,6 +9,8 @@ #include <stdlib.h> #include <stdio.h> +#include <assert.h> + #include "sets.h" /* Question théorique pertinente : @@ -92,6 +94,7 @@ set copy_set(const set s) { for (iter = s->first->next; iter != NULL; iter = iter->next) { element e = malloc(sizeof(struct set_elt)); + assert(e != NULL); e->value = iter->value; prev->next = e; prev = e; |