Code

conf.c: use g_mkdir for WIN32 compatibility
authorJonathan Neuschäfer <j.neuschaefer@gmx.net>
Tue, 27 Dec 2011 23:08:53 +0000 (00:08 +0100)
committerJonathan Neuschäfer <j.neuschaefer@gmx.net>
Wed, 4 Jan 2012 17:48:06 +0000 (18:48 +0100)
This patch is a follow-up to release-0.19-59-g3aea924.

src/conf.c

index 7f3ddd51814b4750c4052a9e0a70c481cc7f75ff..e5c5ab6d7f593fb820555bfdbd9bfc6b5dd59d82 100644 (file)
 #include <stdlib.h>
 #include <unistd.h>
 #include <string.h>
-#include <sys/types.h>
-#include <sys/stat.h>
 #include <fcntl.h>
 #include <glib.h>
+#include <glib/gstdio.h>
 
 #define MAX_LINE_LENGTH 1024
 #define COMMENT_TOKEN '#'
@@ -596,11 +595,7 @@ check_user_conf_dir(void)
                return 0;
        }
 
-#ifndef WIN32
-       retval = mkdir(directory, 0755);
-#else
-       retval = mkdir(directory);
-#endif
+       retval = g_mkdir(directory, 0755);
        g_free(directory);
        return retval;
 }