Neil discovered a bad DECREF on warnoptions, that caused repeated

re-initializing Python (Py_Finalize() followed by Py_Initialize()) to
blow up quickly.  With the DECREF removed I can't get it to fail any
more.  (Except it still leaks, but that's probably a separate issue.)
This commit is contained in:
Guido van Rossum 2001-01-13 22:06:05 +00:00
parent 5ceadc8cba
commit 03df3b3bc1
1 changed files with 1 additions and 2 deletions

View File

@ -634,8 +634,7 @@ _PySys_Init(void)
Py_INCREF(warnoptions);
}
if (warnoptions != NULL) {
PyDict_SetItemString(sysdict, "warnoptions", v = warnoptions);
Py_DECREF(v);
PyDict_SetItemString(sysdict, "warnoptions", warnoptions);
}
if (PyErr_Occurred())