From 623c64fa473cdea90ef332a1a0b2fe759e3de215 Mon Sep 17 00:00:00 2001 From: Travis Oliphant Date: Fri, 26 Oct 2007 22:19:25 +0000 Subject: Fix label problem on wide builds. --- numpy/core/src/scalartypes.inc.src | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) (limited to 'numpy') diff --git a/numpy/core/src/scalartypes.inc.src b/numpy/core/src/scalartypes.inc.src index 3371722d1..244d73ebe 100644 --- a/numpy/core/src/scalartypes.inc.src +++ b/numpy/core/src/scalartypes.inc.src @@ -1299,13 +1299,17 @@ gentype_reduce(PyObject *self, PyObject *args) mod = PyString_FromStringAndSize(buffer, buflen); if (mod == NULL) { Py_DECREF(ret); +#ifndef Py_UNICODE_WIDE ret = NULL; goto fail; +#else + return NULL; +#endif } PyTuple_SET_ITEM(ret, 1, Py_BuildValue("NN", obj, mod)); - fail: #ifndef Py_UNICODE_WIDE + fail: if (alloc) _pya_free((char *)buffer); #endif } -- cgit v1.2.1