]> granicus.if.org Git - python/commitdiff
use logical rather than bit and
authorBenjamin Peterson <benjamin@python.org>
Sun, 11 May 2014 23:17:02 +0000 (16:17 -0700)
committerBenjamin Peterson <benjamin@python.org>
Sun, 11 May 2014 23:17:02 +0000 (16:17 -0700)
Modules/_operator.c

index e8bef04f84af090cd936ab86c6770f8c393aa942..adeb99e90adacda373df1c6089ba0b2711186be2 100644 (file)
@@ -277,7 +277,7 @@ compare_digest(PyObject *self, PyObject *args)
         Py_buffer view_a;
         Py_buffer view_b;
 
-        if ((PyObject_CheckBuffer(a) == 0) & (PyObject_CheckBuffer(b) == 0)) {
+        if (PyObject_CheckBuffer(a) == 0 && PyObject_CheckBuffer(b) == 0) {
             PyErr_Format(PyExc_TypeError,
                          "unsupported operand types(s) or combination of types: "
                          "'%.100s' and '%.100s'",