mirror of
https://github.com/python/cpython.git
synced 2025-08-03 16:39:00 +00:00
New exception interface
This commit is contained in:
parent
d2c0ec78d2
commit
55e3927f58
4 changed files with 5 additions and 18 deletions
|
@ -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);
|
||||
}
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue