diff options
Diffstat (limited to 'Modules/stdwinmodule.c')
-rw-r--r-- | Modules/stdwinmodule.c | 6 |
1 files changed, 2 insertions, 4 deletions
diff --git a/Modules/stdwinmodule.c b/Modules/stdwinmodule.c index a67bc33..0403138 100644 --- a/Modules/stdwinmodule.c +++ b/Modules/stdwinmodule.c @@ -2651,13 +2651,11 @@ initstdwin() d = PyModule_GetDict(m); /* Initialize stdwin.error exception */ - StdwinError = PyString_FromString("stdwin.error"); + StdwinError = PyErr_NewException("stdwin.error", NULL, NULL); if (StdwinError == NULL || PyDict_SetItemString(d, "error", StdwinError) != 0) - Py_FatalError("can't define stdwin.error"); + return; #ifdef WITH_THREAD StdwinLock = allocate_lock(); - if (StdwinLock == NULL) - Py_FatalError("can't allocate stdwin lock"); #endif } |