38 #include "dlist_tests.h" |
38 #include "dlist_tests.h" |
39 #include "string_tests.h" |
39 #include "string_tests.h" |
40 #include "mpool_tests.h" |
40 #include "mpool_tests.h" |
41 #include "map_tests.h" |
41 #include "map_tests.h" |
42 #include "buffer_tests.h" |
42 #include "buffer_tests.h" |
43 |
|
44 int cmp_string(void* o1, void* o2, void* data) { |
|
45 return strcmp((char*)o1, (char*)o2); |
|
46 } |
|
47 |
43 |
48 void* copy_string(void* e, void* data) { |
44 void* copy_string(void* e, void* data) { |
49 char *str = (char*) e; |
45 char *str = (char*) e; |
50 size_t n = 1+strlen(str); |
46 size_t n = 1+strlen(str); |
51 char *cpy = (char*) malloc(n); |
47 char *cpy = (char*) malloc(n); |