Merge "Try 5 times for rmdir command call after umount"

This commit is contained in:
Jenkins 2015-04-21 21:22:19 +00:00 committed by Gerrit Code Review
commit 212da2f149

View File

@ -86,7 +86,10 @@ function run_d_in_target () {
trap - ERR
check_break after-$1 run_in_target bash
sudo umount -f $TMP_MOUNT_PATH/tmp/in_target.d
sudo rmdir $TMP_MOUNT_PATH/tmp/in_target.d
if ! timeout 5 sh -c " while ! sudo rmdir $TMP_MOUNT_PATH/tmp/in_target.d; do sleep 1; done"; then
echo "ERROR: unable to cleanly remove $TMP_MOUNT_PATH/tmp/in_target.d"
exit 1
fi
fi
}