]> git.ipfire.org Git - thirdparty/systemd.git/commitdiff
test/udev-test.pl: suppress umount error message at startup
authorMartin Wilck <mwilck@suse.com>
Thu, 26 Apr 2018 11:25:11 +0000 (13:25 +0200)
committerMichal Sekletár <msekleta@redhat.com>
Mon, 2 Nov 2020 10:43:15 +0000 (11:43 +0100)
umount emits an error message "no mount point specified" if the
tmpfs isn't mounted yet, which is the normal case.
Suppress that by redirecting stderr.

test/udev-test.pl

index 790387e68092499ebc8e7c1c789d24aa92563edc..5e362db6c55845ee7e7c7598f8ffb71d27c0f491 100755 (executable)
@@ -2405,7 +2405,7 @@ sub major_minor_test {
 }
 
 sub udev_setup {
-        system("umount", $udev_tmpfs);
+        system("umount \"$udev_tmpfs\" 2>/dev/null");
         rmdir($udev_tmpfs);
         mkdir($udev_tmpfs) || die "unable to create udev_tmpfs: $udev_tmpfs\n";