]> granicus.if.org Git - python/commitdiff
bpo-29768: Fixed compile-time check for expat version. (#574)
authorSerhiy Storchaka <storchaka@gmail.com>
Thu, 9 Mar 2017 07:47:52 +0000 (09:47 +0200)
committerGitHub <noreply@github.com>
Thu, 9 Mar 2017 07:47:52 +0000 (09:47 +0200)
Modules/pyexpat.c

index e0c9be732e35be1ad189e4f1943c82cf46bf867b..653295bc1f1e2abebf6e620c62fa4ed7cb6b3ed1 100644 (file)
@@ -1188,7 +1188,7 @@ newxmlparseobject(const char *encoding, const char *namespace_separator, PyObjec
         Py_DECREF(self);
         return NULL;
     }
-#if ((XML_MAJOR_VERSION >= 2) && (XML_MINOR_VERSION >= 1)) || defined(XML_HAS_SET_HASH_SALT)
+#if XML_COMBINED_VERSION >= 20100 || defined(XML_HAS_SET_HASH_SALT)
     /* This feature was added upstream in libexpat 2.1.0.  Our expat copy
      * has a backport of this feature where we also define XML_HAS_SET_HASH_SALT
      * to indicate that we can still use it. */