From bd2af6e4ea6e4d32f8a8ce4512b2f1b13153abeb Mon Sep 17 00:00:00 2001 From: Zack Middleton Date: Wed, 7 Jan 2015 18:16:27 -0600 Subject: [PATCH] Use MSVC mode marcos for creat in q3cpp on Windows Using unix mode 0666 for creat was causing crashes when compiled with MSVC. So use the marcos recommended by MSDN. MinGW also has the marcos, so apply to Windows builds in general. --- code/tools/lcc/cpp/unix.c | 8 +++++++- 1 file changed, 7 insertions(+), 1 deletion(-) diff --git a/code/tools/lcc/cpp/unix.c b/code/tools/lcc/cpp/unix.c index bd879448..3e70b562 100644 --- a/code/tools/lcc/cpp/unix.c +++ b/code/tools/lcc/cpp/unix.c @@ -2,6 +2,7 @@ #include #include #include +#include #include "cpp.h" extern int lcc_getopt(int, char *const *, const char *); @@ -66,7 +67,12 @@ setup(int argc, char **argv) error(FATAL, "Can't open input file %s", fp); } if (optind+1