]> granicus.if.org Git - python/commitdiff
#10804: fix copy-paste error when checking assigned fields for NULL.
authorGeorg Brandl <georg@python.org>
Sun, 2 Jan 2011 14:20:16 +0000 (14:20 +0000)
committerGeorg Brandl <georg@python.org>
Sun, 2 Jan 2011 14:20:16 +0000 (14:20 +0000)
Modules/_json.c

index 12ddea2bce8d6ccd41af94e1463252bd3c5d48ff..71d3e58297d6123d2d2839a0fd627f781c73f182 100644 (file)
@@ -1732,7 +1732,7 @@ scanner_init(PyObject *self, PyObject *args, PyObject *kwds)
     if (s->object_hook == NULL)
         goto bail;
     s->pairs_hook = PyObject_GetAttrString(ctx, "object_pairs_hook");
-    if (s->object_hook == NULL)
+    if (s->pairs_hook == NULL)
         goto bail;
     s->parse_float = PyObject_GetAttrString(ctx, "parse_float");
     if (s->parse_float == NULL)