From a0deb6402429f4b541aa38aac095ffe422b8f88e Mon Sep 17 00:00:00 2001 From: Guido van Rossum Date: Wed, 14 Oct 1998 13:45:06 +0000 Subject: [PATCH] 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. --- Modules/arraymodule.c | 5 ++--- 1 file changed, 2 insertions(+), 3 deletions(-) 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 */ } -- 2.50.1