X-Git-Url: https://git.ozlabs.org/?a=blobdiff_plain;f=ccan%2Fstrmap%2Ftest%2Frun-order.c;h=b541666d81209820f62d37418476ee51a1f22a88;hb=ab244401cdba4513f3a3064c5f403fc2a59bf017;hp=417a7406b537a173d3b5b99701c60505e2bcc94b;hpb=20f3b260313fb4d5566aeb0d0c5439574e914e2d;p=ccan diff --git a/ccan/strmap/test/run-order.c b/ccan/strmap/test/run-order.c index 417a7406..b541666d 100644 --- a/ccan/strmap/test/run-order.c +++ b/ccan/strmap/test/run-order.c @@ -11,7 +11,7 @@ static bool in_order(const char *member, char *value, unsigned int *count) ok1(i == atoi(value)); ok1(*count == i); (*count)++; - return false; + return true; } static bool in_order_by_2(const char *member, char *value, unsigned int *count) @@ -20,7 +20,7 @@ static bool in_order_by_2(const char *member, char *value, unsigned int *count) ok1(i == atoi(value)); ok1(*count == i); (*count) += 2; - return false; + return true; } static bool dump(const char *member, char *value, bool *ok) @@ -28,14 +28,12 @@ static bool dump(const char *member, char *value, bool *ok) diag("%s=>%s", member, value); if (value != member + 1) *ok = false; - return false; + return true; } int main(void) { - struct strmap_charp { - STRMAP_MEMBERS(char *); - } map; + STRMAP(char *) map; unsigned int i; char *str[NUM]; bool dump_ok;