]> granicus.if.org Git - python/commitdiff
- do not start collection during processing of an exception
authorNeil Schemenauer <nascheme@enme.ucalgary.ca>
Wed, 4 Oct 2000 16:25:07 +0000 (16:25 +0000)
committerNeil Schemenauer <nascheme@enme.ucalgary.ca>
Wed, 4 Oct 2000 16:25:07 +0000 (16:25 +0000)
Modules/gcmodule.c

index cf884814d2309220e82a0041f66a8eb04d2efd0a..ba950327770fc7f1b952ad880accf4cad9662d3a 100644 (file)
@@ -502,7 +502,11 @@ _PyGC_Insert(PyObject *op)
                abort();
        }
 #endif
-       if (allocated > threshold0 && enabled && threshold0 && !collecting) {
+       if (allocated > threshold0 &&
+           enabled &&
+           threshold0 &&
+           !collecting &&
+           !PyErr_Occurred()) {
                collecting++;
                collect_generations();
                collecting--;