aboutsummaryrefslogtreecommitdiff
path: root/doc/examples/logging.c
diff options
context:
space:
mode:
Diffstat (limited to 'doc/examples/logging.c')
-rw-r--r--doc/examples/logging.c17
1 files changed, 12 insertions, 5 deletions
diff --git a/doc/examples/logging.c b/doc/examples/logging.c
index 239fbe7d..a88f461e 100644
--- a/doc/examples/logging.c
+++ b/doc/examples/logging.c
@@ -15,11 +15,16 @@
15 15
16 16
17static int 17static int
18print_out_key (void *cls, enum MHD_ValueKind kind, const char *key, 18print_out_key (void *cls,
19 const char *value) 19 enum MHD_ValueKind kind,
20 const char *key,
21 const char *value,
22 size_t value_size)
20{ 23{
21 (void)cls; /* Unused. Silent compiler warning. */ 24 (void) cls; /* Unused. Silent compiler warning. */
22 (void)kind; /* Unused. Silent compiler warning. */ 25 (void) kind; /* Unused. Silent compiler warning. */
26 (void) value_size;
27
23 printf ("%s: %s\n", key, value); 28 printf ("%s: %s\n", key, value);
24 return MHD_YES; 29 return MHD_YES;
25} 30}
@@ -38,7 +43,9 @@ answer_to_connection (void *cls, struct MHD_Connection *connection,
38 (void)con_cls; /* Unused. Silent compiler warning. */ 43 (void)con_cls; /* Unused. Silent compiler warning. */
39 printf ("New %s request for %s using version %s\n", method, url, version); 44 printf ("New %s request for %s using version %s\n", method, url, version);
40 45
41 MHD_get_connection_values (connection, MHD_HEADER_KIND, print_out_key, 46 MHD_get_connection_values (connection,
47 MHD_HEADER_KIND,
48 &print_out_key,
42 NULL); 49 NULL);
43 50
44 return MHD_NO; 51 return MHD_NO;