Raise a SystemExit exception to prevent backtrace

This commit is contained in:
Max Howell 2009-08-23 17:56:27 +01:00
parent f0c7e944bb
commit 4671526d70

View File

@ -43,11 +43,9 @@ end
def interactive_shell def interactive_shell
pid=fork pid=fork
if pid.nil? exec ENV['SHELL'] if pid.nil?
exec ENV['SHELL'] Process.wait pid
else raise SystemExit, "Aborting due to non-zero exit status" if $? != 0
Process.wait pid
end
end end
# Kernel.system but with exceptions # Kernel.system but with exceptions