diff options
Diffstat (limited to 'Modules')
-rw-r--r-- | Modules/_tkinter.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/Modules/_tkinter.c b/Modules/_tkinter.c index 0717594..4df45ad 100644 --- a/Modules/_tkinter.c +++ b/Modules/_tkinter.c @@ -913,8 +913,10 @@ AsObj(PyObject *value) return NULL; } argv = (Tcl_Obj **) ckalloc(((size_t)size) * sizeof(Tcl_Obj *)); - if(!argv) - return 0; + if(!argv) { + PyErr_NoMemory(); + return NULL; + } for (i = 0; i < size; i++) argv[i] = AsObj(PySequence_Fast_GET_ITEM(value,i)); result = Tcl_NewListObj(size, argv); |