]> granicus.if.org Git - python/commitdiff
Fix check for error condition
authorAndrew M. Kuchling <amk@amk.ca>
Wed, 15 Jun 2005 18:46:50 +0000 (18:46 +0000)
committerAndrew M. Kuchling <amk@amk.ca>
Wed, 15 Jun 2005 18:46:50 +0000 (18:46 +0000)
Modules/_cursesmodule.c

index 2e14abb7797b5f0fa0d1c54fe1109d731e1da92a..acff973f2a0a07afc1e5343b8b01eb92a0e11c94 100644 (file)
@@ -2107,7 +2107,7 @@ PyCurses_Pair_Content(PyObject *self, PyObject *args)
     return NULL;
   }
 
-  if (!pair_content(pair, &f, &b)) {
+  if (pair_content(pair, &f, &b)==ERR) {
     PyErr_SetString(PyCursesError,
                    "Argument 1 was out of range. (1..COLOR_PAIRS-1)");
     return NULL;