diff options
Diffstat (limited to 'src/microhttpd/test_str_token.c')
-rw-r--r-- | src/microhttpd/test_str_token.c | 13 |
1 files changed, 10 insertions, 3 deletions
diff --git a/src/microhttpd/test_str_token.c b/src/microhttpd/test_str_token.c index 0baca53d..1e1eab28 100644 --- a/src/microhttpd/test_str_token.c +++ b/src/microhttpd/test_str_token.c | |||
@@ -41,6 +41,7 @@ expect_found_n (const char *str, const char *token, size_t token_len) | |||
41 | return 0; | 41 | return 0; |
42 | } | 42 | } |
43 | 43 | ||
44 | |||
44 | #define expect_found(s,t) expect_found_n ((s),(t),MHD_STATICSTR_LEN_ (t)) | 45 | #define expect_found(s,t) expect_found_n ((s),(t),MHD_STATICSTR_LEN_ (t)) |
45 | 46 | ||
46 | static int | 47 | static int |
@@ -56,10 +57,12 @@ expect_not_found_n (const char *str, const char *token, size_t token_len) | |||
56 | return 0; | 57 | return 0; |
57 | } | 58 | } |
58 | 59 | ||
60 | |||
59 | #define expect_not_found(s,t) expect_not_found_n ((s),(t),MHD_STATICSTR_LEN_ ( \ | 61 | #define expect_not_found(s,t) expect_not_found_n ((s),(t),MHD_STATICSTR_LEN_ ( \ |
60 | t)) | 62 | t)) |
61 | 63 | ||
62 | int check_match (void) | 64 | int |
65 | check_match (void) | ||
63 | { | 66 | { |
64 | int errcount = 0; | 67 | int errcount = 0; |
65 | errcount += expect_found ("string", "string"); | 68 | errcount += expect_found ("string", "string"); |
@@ -85,7 +88,9 @@ int check_match (void) | |||
85 | return errcount; | 88 | return errcount; |
86 | } | 89 | } |
87 | 90 | ||
88 | int check_not_match (void) | 91 | |
92 | int | ||
93 | check_not_match (void) | ||
89 | { | 94 | { |
90 | int errcount = 0; | 95 | int errcount = 0; |
91 | errcount += expect_not_found ("strin", "string"); | 96 | errcount += expect_not_found ("strin", "string"); |
@@ -111,7 +116,9 @@ int check_not_match (void) | |||
111 | return errcount; | 116 | return errcount; |
112 | } | 117 | } |
113 | 118 | ||
114 | int main (int argc, char *argv[]) | 119 | |
120 | int | ||
121 | main (int argc, char *argv[]) | ||
115 | { | 122 | { |
116 | int errcount = 0; | 123 | int errcount = 0; |
117 | (void) argc; (void) argv; /* Unused. Silent compiler warning. */ | 124 | (void) argc; (void) argv; /* Unused. Silent compiler warning. */ |