]> granicus.if.org Git - python/commitdiff
Fix small omission: with all the new code, sys.exit(None) would print
authorGuido van Rossum <guido@python.org>
Fri, 3 Oct 1997 13:53:28 +0000 (13:53 +0000)
committerGuido van Rossum <guido@python.org>
Fri, 3 Oct 1997 13:53:28 +0000 (13:53 +0000)
"None"; this should be equivalent to sys.exit(0).

Python/pythonrun.c

index e5dc41fa93a57861d309a3efafc91eb5d3579d45..dfdc711a707a1f33833bc4e23255ed1a6b5bfa54 100644 (file)
@@ -656,6 +656,8 @@ PyErr_Print()
                        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