diff --git a/src/civetweb.c b/src/civetweb.c index aaf90ac5..30b388f0 100755 --- a/src/civetweb.c +++ b/src/civetweb.c @@ -129,6 +129,7 @@ mg_static_assert(sizeof(void *) >= sizeof(int), "data type size check"); #include #include #include +#include /* clock_gettime is not implemented on OSX */ int clock_gettime(int clk_id, struct timespec *t); @@ -136,7 +137,7 @@ int clock_gettime(int clk_id, struct timespec *t); int clock_gettime(int clk_id, struct timespec *t) { - memset(t, 0, sizeof(*t); + memset(t, 0, sizeof(*t)); if (clk_id == CLOCK_REALTIME) { struct timeval now; int rv = gettimeofday(&now, NULL); @@ -179,7 +180,6 @@ clock_gettime(int clk_id, struct timespec *t) #include #include #include -#include #include #include #include