Commit 57caede4 authored by Alexander Belopolsky's avatar Alexander Belopolsky

Issue #15973: fixed 3.2 backport.

parent 6f543a30
......@@ -3243,8 +3243,10 @@ static PyObject *
timezone_richcompare(PyDateTime_TimeZone *self,
PyDateTime_TimeZone *other, int op)
{
if (op != Py_EQ && op != Py_NE)
Py_RETURN_NOTIMPLEMENTED;
if (op != Py_EQ && op != Py_NE) {
Py_INCREF(Py_NotImplemented);
return Py_NotImplemented;
}
if (Py_TYPE(other) != &PyDateTime_TimeZoneType) {
if (op == Py_EQ)
Py_RETURN_FALSE;
......
Markdown is supported
0%
or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment