From: Lennart Poettering Date: Wed, 3 Dec 2014 16:52:51 +0000 (+0100) Subject: nspawn: correct EEXIST check when creating directory to mount /tmp in X-Git-Tag: v218~141 X-Git-Url: http://www.chiark.greenend.org.uk/ucgi/~ianmdlvl/git?a=commitdiff_plain;h=04a919394069cf024559f78eb46692a3739641eb;p=elogind.git nspawn: correct EEXIST check when creating directory to mount /tmp in https://bugs.freedesktop.org/show_bug.cgi?id=86309 --- diff --git a/src/nspawn/nspawn.c b/src/nspawn/nspawn.c index fed150e36..48ef7d07e 100644 --- a/src/nspawn/nspawn.c +++ b/src/nspawn/nspawn.c @@ -808,8 +808,8 @@ static int mount_tmpfs(const char *dest) { return log_oom(); r = mkdir_label(where, 0755); - if (r < 0 && errno != EEXIST) - return log_error_errno(r, "creating mount point for tmpfs %s failed: %m", where); + if (r < 0 && r != -EEXIST) + return log_error_errno(r, "Creating mount point for tmpfs %s failed: %m", where); if (mount("tmpfs", where, "tmpfs", MS_NODEV|MS_STRICTATIME, *o) < 0) return log_error_errno(errno, "tmpfs mount to %s failed: %m", where);