From 7d97075f02527bcf29318143c2fc3650be79ee07 Mon Sep 17 00:00:00 2001 From: Colin Percival Date: Wed, 19 Nov 2014 22:17:22 +0000 Subject: [PATCH] Silence errors when umounting the chroot's /dev, since it probably doesn't exist when we're running this. Unmount filesystems before attempting to destroy the md which holds them. --- release/tools/vmimage.subr | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/release/tools/vmimage.subr b/release/tools/vmimage.subr index 00a0a2e23da3..3e1ddce66b14 100644 --- a/release/tools/vmimage.subr +++ b/release/tools/vmimage.subr @@ -42,11 +42,11 @@ err() { } cleanup() { + umount ${DESTDIR}/dev 2>/dev/null + umount ${DESTDIR} if [ ! -z "${mddev}" ]; then mdconfig -d -u ${mddev} fi - umount ${DESTDIR}/dev - umount ${DESTDIR} return 0 }