From: Daniel Carl <danielcarl@gmx.de>
Date: Wed, 26 Apr 2017 20:13:36 +0000 (+0200)
Subject: Fixed wrongs check of g_mkdir_with_parents #381.
X-Git-Url: https://git.owens.tech///git?a=commitdiff_plain;h=edd5bec6617d600617b7925ce3e811a7c43502a5;p=vimb.git

Fixed wrongs check of g_mkdir_with_parents #381.
---

diff --git a/src/util.c b/src/util.c
index 8f1c2b4..b19aeaa 100644
--- a/src/util.c
+++ b/src/util.c
@@ -101,7 +101,7 @@ void util_cleanup(void)
 
 gboolean util_create_dir_if_not_exists(const char *dirpath)
 {
-    if (!g_mkdir_with_parents(dirpath, 0755)) {
+    if (g_mkdir_with_parents(dirpath, 0755) == -1) {
         g_critical("Could not create directory '%s': %s", dirpath, strerror(errno));
 
         return FALSE;