summaryrefslogtreecommitdiff
path: root/src/cryptsetup
diff options
context:
space:
mode:
authorLennart Poettering <lennart@poettering.net>2012-04-22 15:33:43 +0200
committerLennart Poettering <lennart@poettering.net>2012-04-22 15:33:43 +0200
commite0295d2651cff034ab8200156f1ece06154b7bbc (patch)
tree237a6241ce0e5f6d9b92c1c427722acd264cdeea /src/cryptsetup
parent59e132a7f416d7c4a33a46d791f250e03d2c2cd0 (diff)
mount: don't fail if fstab doesn't exist
Diffstat (limited to 'src/cryptsetup')
-rw-r--r--src/cryptsetup/cryptsetup.c3
1 files changed, 2 insertions, 1 deletions
diff --git a/src/cryptsetup/cryptsetup.c b/src/cryptsetup/cryptsetup.c
index f214d60d56..3ff0ddf2cc 100644
--- a/src/cryptsetup/cryptsetup.c
+++ b/src/cryptsetup/cryptsetup.c
@@ -190,7 +190,8 @@ static char *disk_mount_point(const char *label) {
if (asprintf(&device, "/dev/mapper/%s", label) < 0)
goto finish;
- if (!(f = setmntent("/etc/fstab", "r")))
+ f = setmntent("/etc/fstab", "r");
+ if (!f)
goto finish;
while ((m = getmntent(f)))