diff Python/pythonrun.c @ 6374:f6ef9af4c8b9 legacy-trunk

Fix small omission: with all the new code, sys.exit(None) would print "None"; this should be equivalent to sys.exit(0).
author Guido van Rossum <guido@python.org>
date Fri, 03 Oct 1997 13:53:28 +0000
parents dfeaf965f48a
children 1afcac7658e5
line wrap: on
line diff
--- a/Python/pythonrun.c	Thu Oct 02 20:36:45 1997 +0000
+++ b/Python/pythonrun.c	Fri Oct 03 13:53:28 1997 +0000
@@ -656,6 +656,8 @@
 			if (code) {
 				Py_DECREF(v);
 				v = code;
+				if (v == Py_None)
+					Py_Exit(0);
 			}
 			/* if we failed to dig out the "code" attribute,
 			   then just let the else clause below print the