grml-chroot: exit with according exit code.
authorMichael Prokop <mika@grml.org>
Tue, 25 May 2010 14:55:14 +0000 (16:55 +0200)
committerMichael Prokop <mika@grml.org>
Tue, 25 May 2010 14:55:14 +0000 (16:55 +0200)
usr_sbin/grml-chroot

index a53412c..b3d1184 100755 (executable)
@@ -90,8 +90,11 @@ mountit "sysfs" "sys"
 mountit "/dev"   "dev"   "--bind"
 if (( $# < 1 )); then
     chroot "$DEST_"
+    RC=$?
 else
     chroot "$DEST_" "$@"
+    RC=$?
 fi
 umount_all
 
+exit $RC