aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorEvgeny Grin (Karlson2k) <k2k@narod.ru>2020-10-05 22:05:03 +0300
committerEvgeny Grin (Karlson2k) <k2k@narod.ru>2020-10-05 22:05:03 +0300
commit7eb3139e9a65cc666a976b7eb811dd9fcb7f5099 (patch)
tree9f9774c539552815fb9f1c13df68512c8d8bfeb8
parent74ccb7ae9db4b2c978c377d4af2b5448ff8a4f26 (diff)
downloadlibmicrohttpd-7eb3139e9a65cc666a976b7eb811dd9fcb7f5099.tar.gz
libmicrohttpd-7eb3139e9a65cc666a976b7eb811dd9fcb7f5099.zip
memorypool: added sanity checks
-rw-r--r--src/microhttpd/memorypool.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/src/microhttpd/memorypool.c b/src/microhttpd/memorypool.c
index 475e4007..4d619464 100644
--- a/src/microhttpd/memorypool.c
+++ b/src/microhttpd/memorypool.c
@@ -65,9 +65,9 @@
65#define ROUND_TO_ALIGN(n) (((n) + (ALIGN_SIZE - 1)) \ 65#define ROUND_TO_ALIGN(n) (((n) + (ALIGN_SIZE - 1)) \
66 / (ALIGN_SIZE) *(ALIGN_SIZE)) 66 / (ALIGN_SIZE) *(ALIGN_SIZE))
67 67
68#if defined(PAGE_SIZE) 68#if defined(PAGE_SIZE) && (0 < (PAGE_SIZE + 0))
69#define MHD_DEF_PAGE_SIZE_ PAGE_SIZE 69#define MHD_DEF_PAGE_SIZE_ PAGE_SIZE
70#elif defined(PAGESIZE) 70#elif defined(PAGESIZE) && (0 < (PAGESIZE + 0))
71#define MHD_DEF_PAGE_SIZE_ PAGESIZE 71#define MHD_DEF_PAGE_SIZE_ PAGESIZE
72#else /* ! PAGESIZE */ 72#else /* ! PAGESIZE */
73#define MHD_DEF_PAGE_SIZE_ (4096) 73#define MHD_DEF_PAGE_SIZE_ (4096)