Do not bail on makepath() fail if dir exists

Signed-off-by: Joachim Nilsson <troglobit@gmail.com>
This commit is contained in:
Joachim Nilsson committed 2016-04-05 03:16:40 +02:00
1 parent 4fecb8621d
commit 05cc6bf5d2
1 file changed
+1 -1
+1 -1
View File
@@ -45,7 +45,7 @@ int cond_set_path(const char *path, enum cond_state new)
_e("Invalid path '%s' for condition", path);
return 0;
}
if (makepath(dir)) {
if (makepath(dir) && errno != EEXIST) {
_pe("Failed creating dir '%s' for condition '%s'", dir, path);
return 0;
}