commit | 0c924f7fe1217f42957956f72ea2c16c4dd84a7a | [log] [tgz] |
---|---|---|
author | Thomas Klausner <tk@giga.or.at> | Wed Jun 21 00:02:11 2017 +0200 |
committer | Thomas Klausner <tk@giga.or.at> | Wed Jun 21 00:02:11 2017 +0200 |
tree | 1b2915ce467c2110afb8ccd11ce80d8845db3b4c | |
parent | 077025d88f1313267801500d1cb26c402da51042 [diff] |
Do not use unistd.h on Windows; include process.h for getpid().
diff --git a/lib/mkstemp.c b/lib/mkstemp.c index 57d8848..cdfc0e2 100644 --- a/lib/mkstemp.c +++ b/lib/mkstemp.c
@@ -39,11 +39,13 @@ #include <errno.h> #include <fcntl.h> #ifdef _WIN32 +#include <process.h> #include <io.h> +#else +#include <unistd.h> #endif #include <stdio.h> #include <stdlib.h> -#include <unistd.h> #ifndef O_BINARY #define O_BINARY 0