[libvirt] [PATCH v2 1/5] virfile: virDirCreate: Fix ALLOW_EXIST conditional

Cole Robinson crobinso at redhat.com
Tue May 5 16:43:59 UTC 2015


I screwed this up in the previous (post 1.2.16) commits
---
 src/util/virfile.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/src/util/virfile.c b/src/util/virfile.c
index 8a06813..6e9ecbe 100644
--- a/src/util/virfile.c
+++ b/src/util/virfile.c
@@ -2289,7 +2289,7 @@ virDirCreateNoFork(const char *path,
     int ret = 0;
     struct stat st;
 
-    if (!((flags & VIR_DIR_CREATE_ALLOW_EXIST) && !virFileExists(path))) {
+    if (!((flags & VIR_DIR_CREATE_ALLOW_EXIST) && virFileExists(path))) {
         if (mkdir(path, mode) < 0) {
             ret = -errno;
             virReportSystemError(errno, _("failed to create directory '%s'"),
-- 
2.4.0




More information about the libvir-list mailing list