test/map_tests.c

changeset 111
c8c59d7f4536
parent 103
08018864fb91
child 112
6384016df2a3
     1.1 --- a/test/map_tests.c	Mon Jul 15 13:53:51 2013 +0200
     1.2 +++ b/test/map_tests.c	Mon Jul 15 14:25:50 2013 +0200
     1.3 @@ -179,7 +179,7 @@
     1.4      int hit = 0;
     1.5  
     1.6      int* v;
     1.7 -    UCX_MAP_FOREACH(v, i) {
     1.8 +    UCX_MAP_FOREACH(key, v, i) {
     1.9          check += *v;
    1.10          hit++;
    1.11      }
    1.12 @@ -274,7 +274,7 @@
    1.13  
    1.14      void *d;
    1.15      UcxMapIterator iter = ucx_map_iterator(map);
    1.16 -    UCX_MAP_FOREACH(d, iter) {
    1.17 +    UCX_MAP_FOREACH(key, d, iter) {
    1.18          free(d);
    1.19      }
    1.20      ucx_map_free(map);
    1.21 @@ -308,7 +308,7 @@
    1.22      UCX_TEST_ASSERT(r == 0, "IO errors, test cannot be performed");
    1.23      UcxMapIterator iter = ucx_map_iterator(map);
    1.24      const char *value; size_t n;
    1.25 -    UCX_MAP_FOREACH(value, iter) {
    1.26 +    UCX_MAP_FOREACH(key, value, iter) {
    1.27          n = strlen(value);
    1.28          UCX_TEST_ASSERT(strncmp((const char*) pool->data[iter.index], value, n),
    1.29                  "values of map does not match pooled values");

mercurial