Don't try to create "" directories
authorPanu Matilainen <pmatilai@redhat.com>
Fri, 9 Jan 2009 13:05:40 +0000 (15:05 +0200)
committerPanu Matilainen <pmatilai@redhat.com>
Fri, 9 Jan 2009 13:05:40 +0000 (15:05 +0200)
rpmio/rpmfileutil.c

index feb799a..5e47db4 100644 (file)
@@ -284,7 +284,7 @@ int rpmioMkpath(const char * path, mode_t mode, uid_t uid, gid_t gid)
     char *d, *de;
     int rc;
 
-    if (path == NULL)
+    if (path == NULL || *path == '\0')
        return -1;
     d = rstrcat(NULL, path);
     if (d[strlen(d)-1] != '/') {