summaryrefslogtreecommitdiffstats
path: root/isys/imount.c
diff options
context:
space:
mode:
authorJeremy Katz <katzj@redhat.com>2008-03-26 16:13:56 -0400
committerJeremy Katz <katzj@redhat.com>2008-03-26 16:25:56 -0400
commitc8f3b9d451d28a3c41125c6d900ecc79aed7f41b (patch)
treea32b858a7505686c1a0c9fd070917f79f7579761 /isys/imount.c
parent24dfac6d653c3d5740bb85b79a5eeb9361a1a17d (diff)
downloadanaconda-c8f3b9d451d28a3c41125c6d900ecc79aed7f41b.tar.gz
anaconda-c8f3b9d451d28a3c41125c6d900ecc79aed7f41b.tar.xz
anaconda-c8f3b9d451d28a3c41125c6d900ecc79aed7f41b.zip
Fix SIGSEGV on all mounts without options
Diffstat (limited to 'isys/imount.c')
-rw-r--r--isys/imount.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/isys/imount.c b/isys/imount.c
index 91201b7ec..0499b44de 100644
--- a/isys/imount.c
+++ b/isys/imount.c
@@ -49,8 +49,8 @@ int doPwMount(char *dev, char *where, char *fs, char *options) {
opts = strdup("nolock");
device = strdup(dev);
} else {
- if (strstr(options, "bind") == NULL && strncmp(dev, "LABEL=", 6) &&
- strncmp(dev, "UUID=", 5) && *dev != '/')
+ if ((options && strstr(options, "bind") == NULL) &&
+ strncmp(dev, "LABEL=", 6) && strncmp(dev, "UUID=", 5) && *dev != '/')
rc = asprintf(&device, "/dev/%s", dev);
else
device = strdup(dev);