summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSebastian Berg <sebastian@sipsolutions.net>2021-03-23 18:15:34 -0500
committerSebastian Berg <sebastian@sipsolutions.net>2021-03-23 18:34:02 -0500
commit0b61abaed5049c148c30766db01b00a940b9b2f8 (patch)
tree6b19ed677acbffd9680c06b71d88aad5a1cb947c
parent605be4f81ffad7475e6e07d6c19fca35c6789c41 (diff)
downloadnumpy-0b61abaed5049c148c30766db01b00a940b9b2f8.tar.gz
BUG: Fix bug(s) introduced due to rebase/merge conflict
-rw-r--r--numpy/core/src/umath/ufunc_object.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/numpy/core/src/umath/ufunc_object.c b/numpy/core/src/umath/ufunc_object.c
index e5b182270..6510709db 100644
--- a/numpy/core/src/umath/ufunc_object.c
+++ b/numpy/core/src/umath/ufunc_object.c
@@ -5578,7 +5578,6 @@ prepare_input_arguments_for_outer(PyObject *args, PyUFuncObject *ufunc)
/* DEPRECATED 2020-05-13, NumPy 1.20 */
if (PyErr_WarnFormat(PyExc_DeprecationWarning, 1,
matrix_deprecation_msg, ufunc->name, "first") < 0) {
- Py_DECREF(tmp);
return NULL;
}
ap1 = (PyArrayObject *) PyArray_FromObject(tmp, NPY_NOTYPE, 0, 0);
@@ -5596,7 +5595,6 @@ prepare_input_arguments_for_outer(PyObject *args, PyUFuncObject *ufunc)
/* DEPRECATED 2020-05-13, NumPy 1.20 */
if (PyErr_WarnFormat(PyExc_DeprecationWarning, 1,
matrix_deprecation_msg, ufunc->name, "second") < 0) {
- Py_DECREF(tmp);
Py_DECREF(ap1);
return NULL;
}
@@ -5646,6 +5644,7 @@ prepare_input_arguments_for_outer(PyObject *args, PyUFuncObject *ufunc)
"To work around this issue, please convert the inputs to "
"numpy arrays.",
ufunc->name, Py_TYPE(ap_new)->tp_name);
+ Py_DECREF(ap_new);
goto fail;
}