From: Daniel Mack Date: Thu, 4 Jun 2015 13:39:49 +0000 (+0200) Subject: core/mount: skip incomplete mountinfo entries X-Git-Tag: v221~182^2 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=refs%2Fpull%2F73%2Fhead;p=thirdparty%2Fsystemd.git core/mount: skip incomplete mountinfo entries Skip /proc/mountinfo entries for which libmount returns a NULL pointer for 'source' or 'target'. This happened on Semaphore CI's build servers when the test suite is run. --- diff --git a/src/core/mount.c b/src/core/mount.c index ba1dcf1e85f..851b41351e6 100644 --- a/src/core/mount.c +++ b/src/core/mount.c @@ -1522,6 +1522,9 @@ static int mount_load_proc_self_mountinfo(Manager *m, bool set_flags) { options = mnt_fs_get_options(fs); fstype = mnt_fs_get_fstype(fs); + if (!device || !path) + continue; + if (cunescape(device, UNESCAPE_RELAX, &d) < 0) return log_oom();