1
0
mirror of https://github.com/systemd/systemd.git synced 2024-11-05 15:21:37 +03:00

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.
This commit is contained in:
Daniel Mack 2015-06-04 15:39:49 +02:00
parent 1cf548925d
commit c0a7f8d3cb

View File

@ -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();