aboutsummaryrefslogtreecommitdiff
path: root/src/examples/https_fileserver_example.c
diff options
context:
space:
mode:
Diffstat (limited to 'src/examples/https_fileserver_example.c')
-rw-r--r--src/examples/https_fileserver_example.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/src/examples/https_fileserver_example.c b/src/examples/https_fileserver_example.c
index babad604..5dc340f7 100644
--- a/src/examples/https_fileserver_example.c
+++ b/src/examples/https_fileserver_example.c
@@ -137,7 +137,7 @@ http_ahc (void *cls,
137 const char *method, 137 const char *method,
138 const char *version, 138 const char *version,
139 const char *upload_data, 139 const char *upload_data,
140 size_t *upload_data_size, void **ptr) 140 size_t *upload_data_size, void **req_cls)
141{ 141{
142 static int aptr; 142 static int aptr;
143 struct MHD_Response *response; 143 struct MHD_Response *response;
@@ -152,13 +152,13 @@ http_ahc (void *cls,
152 152
153 if (0 != strcmp (method, MHD_HTTP_METHOD_GET)) 153 if (0 != strcmp (method, MHD_HTTP_METHOD_GET))
154 return MHD_NO; /* unexpected method */ 154 return MHD_NO; /* unexpected method */
155 if (&aptr != *ptr) 155 if (&aptr != *req_cls)
156 { 156 {
157 /* do never respond on first call */ 157 /* do never respond on first call */
158 *ptr = &aptr; 158 *req_cls = &aptr;
159 return MHD_YES; 159 return MHD_YES;
160 } 160 }
161 *ptr = NULL; /* reset when done */ 161 *req_cls = NULL; /* reset when done */
162 162
163 file = fopen (&url[1], "rb"); 163 file = fopen (&url[1], "rb");
164 if (NULL != file) 164 if (NULL != file)