Fixed compilation with microhttpd >= 0.9.2
[psensor.git] / src / server / server.c
index a87ec64..b00f8ae 100644 (file)
@@ -130,8 +130,13 @@ char *get_path(const char *url, const char *www_dir)
        return res;
 }
 
+#if MHD_VERSION >= 0x00090200
+static int
+file_reader(void *cls, uint64_t pos, char *buf, size_t max)
+#else
 static int
 file_reader(void *cls, uint64_t pos, char *buf, int max)
+#endif
 {
        FILE *file = cls;