While 'errno' can be defined in various headers, by standard it must be defined in <errno.h> header.
@@ -43,6 +43,7 @@
#endif /* MHD_HAVE_LIBMAGIC */
#include <limits.h>
#include <ctype.h>
+#include <errno.h>
#if defined(MHD_CPU_COUNT) && (MHD_CPU_COUNT + 0) < 2
#undef MHD_CPU_COUNT
@@ -45,6 +45,7 @@
@@ -27,6 +27,7 @@
#include "platform.h"
#include <microhttpd.h>
#include <stdlib.h>
#define PAGE \
"<html><head><title>libmicrohttpd demo</title></head>" \
@@ -31,6 +31,7 @@
#ifdef HAVE_UNISTD_H
#include <unistd.h>
#endif
static ssize_t
@@ -28,6 +28,7 @@
#include <sys/stat.h>
"<html><head><title>File not found</title></head><body>File not found</body></html>"
@@ -30,6 +30,7 @@
#include <sys/epoll.h>
#include <sys/timerfd.h>
#define TIMEOUT_INFINITE -1
@@ -33,6 +33,7 @@
#include <pthread.h>
"<html><head><title>libmicrohttpd demo</title></head><body>libmicrohttpd demo</body></html>"
#define _CRT_SECURE_NO_WARNINGS
#include <microhttpd_ws.h>
#if defined(WIN32) || defined(_WIN32) || defined(__WIN32__) || defined(__NT__)
@@ -29,6 +29,7 @@
/* TODO: allow to send large messages. */
@@ -54,10 +54,11 @@
#include <sys/eventfd.h>
#include <stdint.h> /* for uint64_t */
-#include <unistd.h> /* for read(), write(), errno */
+#include <unistd.h> /* for read(), write() */
#endif /* HAVE_UNISTD_H */
#ifdef HAVE_STRING_H
#include <string.h> /* for strerror() */
@@ -26,6 +26,7 @@
#include "mhd_options.h"
#include <string.h>
#include <stdio.h>
#include "gen_auth.h"
#ifdef BAUTH_SUPPORT
#include "basicauth.h"
#include <time.h>
#include <stdint.h>
#ifdef HAVE_STRINGS_H
#include <strings.h>
@@ -34,6 +34,7 @@
#include "mhd_sockets.h"
#include <stddef.h>
#ifndef WINDOWS
@@ -35,6 +35,7 @@
#include "mhd_has_in_name.h"
@@ -42,6 +42,7 @@
@@ -32,6 +32,7 @@
#include "mhd_has_param.h"
#include "mhd_sockets.h" /* only macros used */
#include <sys/socket.h>
#include <curl/curl.h>
struct callback_closure
{
#if defined(MHD_HTTPS_REQUIRE_GCRYPT) && \
(defined(MHD_SHA256_TLSLIB) || defined(MHD_MD5_TLSLIB))
@@ -38,6 +38,7 @@
#define NEED_GCRYP_INIT 1
#include <gcrypt.h>
#endif /* MHD_HTTPS_REQUIRE_GCRYPT && (MHD_SHA256_TLSLIB || MHD_MD5_TLSLIB) */
@@ -36,6 +36,7 @@
@@ -44,6 +44,7 @@
#ifdef HAVE_STDBOOL_H
#include <stdbool.h>
#include <sys/types.h>
#include <sys/wait.h>
#include <fcntl.h>
#ifndef _WIN32
#include <signal.h>
#endif /* _WIN32 */
#endif /* MHD_HTTPS_REQUIRE_GCRYPT */
@@ -39,6 +39,7 @@