diff options
author | Gerhard Häring <gh@ghaering.de> | 2008-03-29 14:11:55 +0000 |
---|---|---|
committer | Gerhard Häring <gh@ghaering.de> | 2008-03-29 14:11:55 +0000 |
commit | 43b842d2a02cbbde74b3ac68102743ec9ddfe46f (patch) | |
tree | 663ae8bc566205840531f849bc74d45f88f98901 /Modules/_sqlite/cursor.c | |
parent | 1c06d306b1cdc235d39b35dfef10ca6a3ff7ad69 (diff) | |
download | cpython-43b842d2a02cbbde74b3ac68102743ec9ddfe46f.tar.gz |
Moved DECREF to correct place to get rid of leaked references.
Diffstat (limited to 'Modules/_sqlite/cursor.c')
-rw-r--r-- | Modules/_sqlite/cursor.c | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/Modules/_sqlite/cursor.c b/Modules/_sqlite/cursor.c index 7fd7db31ee..8efa812719 100644 --- a/Modules/_sqlite/cursor.c +++ b/Modules/_sqlite/cursor.c @@ -355,9 +355,9 @@ PyObject* _pysqlite_fetch_one_row(pysqlite_Cursor* self) error_obj = PyUnicode_FromEncodedObject(buf_bytes, "ascii", "replace"); if (!error_obj) { PyErr_SetString(pysqlite_OperationalError, "Could not decode to UTF-8"); - Py_DECREF(error_obj); } else { PyErr_SetObject(pysqlite_OperationalError, error_obj); + Py_DECREF(error_obj); } Py_DECREF(buf_bytes); } |