diff options
Diffstat (limited to 'src/examples/digest_auth_example.c')
-rw-r--r-- | src/examples/digest_auth_example.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/src/examples/digest_auth_example.c b/src/examples/digest_auth_example.c index 4b00669f..889967fb 100644 --- a/src/examples/digest_auth_example.c +++ b/src/examples/digest_auth_example.c | |||
@@ -54,7 +54,7 @@ ahc_echo (void *cls, | |||
54 | (void)ptr; /* Unused. Silent compiler warning. */ | 54 | (void)ptr; /* Unused. Silent compiler warning. */ |
55 | 55 | ||
56 | username = MHD_digest_auth_get_username(connection); | 56 | username = MHD_digest_auth_get_username(connection); |
57 | if (username == NULL) | 57 | if (NULL == username) |
58 | { | 58 | { |
59 | response = MHD_create_response_from_buffer(strlen (DENIED), | 59 | response = MHD_create_response_from_buffer(strlen (DENIED), |
60 | DENIED, | 60 | DENIED, |
@@ -70,7 +70,7 @@ ahc_echo (void *cls, | |||
70 | username, | 70 | username, |
71 | password, | 71 | password, |
72 | 300); | 72 | 300); |
73 | free(username); | 73 | MHD_free (username); |
74 | if ( (ret == MHD_INVALID_NONCE) || | 74 | if ( (ret == MHD_INVALID_NONCE) || |
75 | (ret == MHD_NO) ) | 75 | (ret == MHD_NO) ) |
76 | { | 76 | { |
@@ -93,6 +93,7 @@ ahc_echo (void *cls, | |||
93 | return ret; | 93 | return ret; |
94 | } | 94 | } |
95 | 95 | ||
96 | |||
96 | int | 97 | int |
97 | main (int argc, char *const *argv) | 98 | main (int argc, char *const *argv) |
98 | { | 99 | { |