diff options
Diffstat (limited to 'Mac/Modules/macmodule.c')
-rw-r--r-- | Mac/Modules/macmodule.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/Mac/Modules/macmodule.c b/Mac/Modules/macmodule.c index 49c0f8b..a7f958e 100644 --- a/Mac/Modules/macmodule.c +++ b/Mac/Modules/macmodule.c @@ -630,7 +630,6 @@ initmac() d = PyModule_GetDict(m); /* Initialize mac.error exception */ - MacError = PyString_FromString("mac.error"); - if (MacError == NULL || PyDict_SetItemString(d, "error", MacError) != 0) - Py_FatalError("can't define mac.error"); + MacError = PyErr_NewException("mac.error", NULL, NULL); + PyDict_SetItemString(d, "error", MacError); } |