diff options
author | Gerhard Häring <gh@ghaering.de> | 2010-03-05 15:20:03 (GMT) |
---|---|---|
committer | Gerhard Häring <gh@ghaering.de> | 2010-03-05 15:20:03 (GMT) |
commit | f9cee224461273307ca9f8a0e690a527496534ab (patch) | |
tree | c12745138703eba02cc59f892cf9f19db6cd7ff5 /Modules/_sqlite/row.c | |
parent | 06dbff3b1f16dc232df0190cfed4b3af81aecda3 (diff) | |
download | cpython-f9cee224461273307ca9f8a0e690a527496534ab.zip cpython-f9cee224461273307ca9f8a0e690a527496534ab.tar.gz cpython-f9cee224461273307ca9f8a0e690a527496534ab.tar.bz2 |
Merged new pysqlite version 2.6.0 from trunk.
Diffstat (limited to 'Modules/_sqlite/row.c')
-rw-r--r-- | Modules/_sqlite/row.c | 20 |
1 files changed, 10 insertions, 10 deletions
diff --git a/Modules/_sqlite/row.c b/Modules/_sqlite/row.c index f9f57e9..0aa78f4 100644 --- a/Modules/_sqlite/row.c +++ b/Modules/_sqlite/row.c @@ -1,6 +1,6 @@ /* row.c - an enhanced tuple for database rows * - * Copyright (C) 2005-2006 Gerhard Häring <gh@ghaering.de> + * Copyright (C) 2005-2010 Gerhard Häring <gh@ghaering.de> * * This file is part of pysqlite. * @@ -172,17 +172,17 @@ static long pysqlite_row_hash(pysqlite_Row *self) static PyObject* pysqlite_row_richcompare(pysqlite_Row *self, PyObject *_other, int opid) { if (opid != Py_EQ && opid != Py_NE) { - Py_INCREF(Py_NotImplemented); - return Py_NotImplemented; + Py_INCREF(Py_NotImplemented); + return Py_NotImplemented; } if (PyType_IsSubtype(Py_TYPE(_other), &pysqlite_RowType)) { - pysqlite_Row *other = (pysqlite_Row *)_other; - PyObject *res = PyObject_RichCompare(self->description, other->description, opid); - if ((opid == Py_EQ && res == Py_True) - || (opid == Py_NE && res == Py_False)) { - Py_DECREF(res); - return PyObject_RichCompare(self->data, other->data, opid); - } + pysqlite_Row *other = (pysqlite_Row *)_other; + PyObject *res = PyObject_RichCompare(self->description, other->description, opid); + if ((opid == Py_EQ && res == Py_True) + || (opid == Py_NE && res == Py_False)) { + Py_DECREF(res); + return PyObject_RichCompare(self->data, other->data, opid); + } } Py_INCREF(Py_NotImplemented); return Py_NotImplemented; |