From: Guido van Rossum Date: Wed, 14 Oct 1998 13:45:06 +0000 (+0000) Subject: No need to issue a fatal error if the PyDict_SetItemString fails; the X-Git-Tag: v1.5.2a2~31 X-Git-Url: https://granicus.if.org/sourcecode?a=commitdiff_plain;h=a0deb6402429f4b541aa38aac095ffe422b8f88e;p=python No need to issue a fatal error if the PyDict_SetItemString fails; the caller (in import.c) will test for errors and take appropriate action. --- diff --git a/Modules/arraymodule.c b/Modules/arraymodule.c index 99481ec8ab..fc31b31e8c 100644 --- a/Modules/arraymodule.c +++ b/Modules/arraymodule.c @@ -1463,7 +1463,6 @@ initarray() PyObject *m, *d; m = Py_InitModule3("array", a_methods, module_doc); d = PyModule_GetDict(m); - if (PyDict_SetItemString(d, "ArrayType", - (PyObject *)&Arraytype) != 0) - Py_FatalError("can't define array.ArrayType"); + PyDict_SetItemString(d, "ArrayType", (PyObject *)&Arraytype); + /* No need to check the error here, the caller will do that */ }