aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorMiss Islington (bot) <31488909+miss-islington@users.noreply.github.com>2019-11-06 21:10:05 -0800
committerGitHub <noreply@github.com>2019-11-06 21:10:05 -0800
commit30114c7119a9ae0e610d6974f57f22d8d05ed50d (patch)
treed94b1cd1e8deec712cc1400d173e24909a4d1f1d
parentbpo-38557: Improve documentation for list and tuple C API. (GH-16925) (diff)
downloadcpython-30114c7119a9ae0e610d6974f57f22d8d05ed50d.tar.gz
cpython-30114c7119a9ae0e610d6974f57f22d8d05ed50d.tar.bz2
cpython-30114c7119a9ae0e610d6974f57f22d8d05ed50d.zip
bpo-37731: Reorder includes in xmltok.c to avoid redefinition of _POSIX_C_SOURCE (GH-16733)
(cherry picked from commit 8177404d520e81f16324a900f093adf3856d33f8) Co-authored-by: Pablo Galindo <Pablogsal@gmail.com>
-rw-r--r--Modules/expat/xmltok.c16
1 files changed, 8 insertions, 8 deletions
diff --git a/Modules/expat/xmltok.c b/Modules/expat/xmltok.c
index 11e9d1ccdad..54cfedb85c2 100644
--- a/Modules/expat/xmltok.c
+++ b/Modules/expat/xmltok.c
@@ -30,6 +30,14 @@
USE OR OTHER DEALINGS IN THE SOFTWARE.
*/
+#ifdef _WIN32
+# include "winconfig.h"
+#else
+# ifdef HAVE_EXPAT_CONFIG_H
+# include <expat_config.h>
+# endif
+#endif /* ndef _WIN32 */
+
#include <stddef.h>
#include <string.h> /* memcpy */
@@ -42,14 +50,6 @@
# include <stdbool.h>
#endif
-#ifdef _WIN32
-# include "winconfig.h"
-#else
-# ifdef HAVE_EXPAT_CONFIG_H
-# include <expat_config.h>
-# endif
-#endif /* ndef _WIN32 */
-
#include "expat_external.h"
#include "internal.h"
#include "xmltok.h"