aboutsummaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
authorDaniel Stenberg <daniel@haxx.se>2003-01-08 15:04:42 +0000
committerDaniel Stenberg <daniel@haxx.se>2003-01-08 15:04:42 +0000
commitcb5ba675a73e7ef9e8ea0ce913bf15ba63f87d1f (patch)
tree5ecb66c3b07e8745ff06367650dc1775dcfbb51c /src
parent2288086695f6eb50a4928e23d8858e303eefe17f (diff)
mkdir() fix for win32
Diffstat (limited to 'src')
-rw-r--r--src/main.c8
1 files changed, 7 insertions, 1 deletions
diff --git a/src/main.c b/src/main.c
index 813bf49cc..233c7b9a1 100644
--- a/src/main.c
+++ b/src/main.c
@@ -145,6 +145,12 @@ char *strdup(char *str)
}
#endif
+#ifdef WIN32
+#include <direct.h>
+#define F_OK 0
+#define mkdir(x,y) (mkdir)(x)
+#endif
+
#ifdef VMS
int vms_show = 0;
#define FAC_CURL 0xC01
@@ -3073,7 +3079,7 @@ static int create_dir_hierarchy(char *outfile)
else
sprintf(dirbuildup,"%s%s", DIR_CHAR, tempdir);
}
- if (access(dirbuildup,F_OK) == -1) {
+ if (access(dirbuildup, F_OK) == -1) {
result = mkdir(dirbuildup,(mode_t)0000750);
if (-1 == result) {
switch (errno) {