diff options
Diffstat (limited to 'Objects/unicodeobject.c')
-rw-r--r-- | Objects/unicodeobject.c | 4 |
1 files changed, 1 insertions, 3 deletions
diff --git a/Objects/unicodeobject.c b/Objects/unicodeobject.c index 5f9f4a7..c1cdebc 100644 --- a/Objects/unicodeobject.c +++ b/Objects/unicodeobject.c @@ -4485,10 +4485,8 @@ int PyUnicode_Contains(PyObject *container, goto onError; } u = (PyUnicodeObject *)PyUnicode_FromObject(container); - if (u == NULL) { - Py_DECREF(v); + if (u == NULL) goto onError; - } size = PyUnicode_GET_SIZE(v); rhs = PyUnicode_AS_UNICODE(v); |