summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/core/misc.c5
1 files changed, 5 insertions, 0 deletions
diff --git a/src/core/misc.c b/src/core/misc.c
index d57c4881..9115f29a 100644
--- a/src/core/misc.c
+++ b/src/core/misc.c
@@ -394,6 +394,11 @@ int mkpath(const char *path, int mode)
g_return_val_if_fail(path != NULL, -1);
p = g_path_skip_root((char *) path);
+ if (p == NULL) {
+ /* not a full path, maybe not what we wanted
+ but continue anyway.. */
+ p = path;
+ }
for (;;) {
if (*p != G_DIR_SEPARATOR && *p != '\0') {
p++;