Only run mdconfig -d -u 3 if /dev/md3 exists on the system

This will prevent "cleanup failures" (exit code != 0 returned) when
tmpfs is not loaded

MFC after:	1 week
This commit is contained in:
ngie 2016-12-09 22:50:43 +00:00
parent fb62448269
commit 56d12910dc

View File

@ -85,7 +85,7 @@ basic_cleanup() {
umount mnt 2>/dev/null 1>&2
# Begin FreeBSD
if true; then
atf_check -s eq:0 -o empty -e empty mdconfig -d -u 3
[ ! -c /dev/md3 ] || mdconfig -d -u 3
else
# End FreeBSD
vndconfig -u /dev/vnd3 2>/dev/null 1>&2