From 1a269c4ee34a4fc98f2407996cc6bda82f3e03bf Mon Sep 17 00:00:00 2001 From: Lennart Poettering Date: Tue, 22 Sep 2020 11:21:19 +0200 Subject: [PATCH] shutdown: don't compare pointers with 0 --- src/shutdown/umount.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/shutdown/umount.c b/src/shutdown/umount.c index 307944c657..4354485728 100644 --- a/src/shutdown/umount.c +++ b/src/shutdown/umount.c @@ -474,11 +474,11 @@ static int delete_dm(dev_t devnum) { } static int delete_md(MountPoint *m) { - _cleanup_close_ int fd = -1; + assert(m); assert(major(m->devnum) != 0); - assert(m->path != 0); + assert(m->path); fd = open(m->path, O_RDONLY|O_CLOEXEC|O_EXCL); if (fd < 0)