diff options
author | mattip <matti.picus@gmail.com> | 2018-12-16 22:35:36 +0200 |
---|---|---|
committer | mattip <matti.picus@gmail.com> | 2018-12-16 22:35:36 +0200 |
commit | 7a7dc347c4edea39e1ffff16df4b5f1921e9e4e3 (patch) | |
tree | d68c4c1194491385ea8e50097c5a4bf3d63738aa /numpy | |
parent | 6379f3eb7c8829100d3f73b26d58ec4f834980fe (diff) | |
download | numpy-7a7dc347c4edea39e1ffff16df4b5f1921e9e4e3.tar.gz |
BUG: be sure to set returned value to NULL
Diffstat (limited to 'numpy')
-rw-r--r-- | numpy/core/src/common/ufunc_override.c | 1 |
1 files changed, 1 insertions, 0 deletions
diff --git a/numpy/core/src/common/ufunc_override.c b/numpy/core/src/common/ufunc_override.c index 079f79065..89f08a9cb 100644 --- a/numpy/core/src/common/ufunc_override.c +++ b/numpy/core/src/common/ufunc_override.c @@ -106,6 +106,7 @@ PyUFuncOverride_GetOutObjects(PyObject *kwds, PyObject **out_kwd_obj, PyObject * seq = PySequence_Fast(*out_kwd_obj, "Could not convert object to sequence"); if (seq == NULL) { + *out_kwd_obj = NULL; return -1; } *out_objs = PySequence_Fast_ITEMS(seq); |