diff options
Diffstat (limited to 'Modules/clmodule.c')
-rw-r--r-- | Modules/clmodule.c | 7 |
1 files changed, 1 insertions, 6 deletions
diff --git a/Modules/clmodule.c b/Modules/clmodule.c index 1550e58310..b8bac317e9 100644 --- a/Modules/clmodule.c +++ b/Modules/clmodule.c @@ -1006,7 +1006,7 @@ initcl() m = Py_InitModule("cl", cl_methods); d = PyModule_GetDict(m); - ClError = PyString_FromString("cl.error"); + ClError = PyErr_NewException("cl.error", NULL, NULL); (void) PyDict_SetItemString(d, "error", ClError); #ifdef CL_ADDED_ALGORITHM_ERROR @@ -2594,10 +2594,5 @@ initcl() Py_DECREF(x); #endif - if (PyErr_Occurred()) { - error: - Py_FatalError("can't initialize module cl"); - } - (void) clSetErrorHandler(cl_ErrorHandler); } |