fix #73
authorMichael Wallner <mike@php.net>
Thu, 1 Feb 2018 13:36:09 +0000 (14:36 +0100)
committerMichael Wallner <mike@php.net>
Thu, 1 Feb 2018 13:36:09 +0000 (14:36 +0100)
include idna.h prior idn2.h to ensure INDA_H is defined and libidn2 does
not try to define the idna compat layer

src/php_http.c
src/php_http_url.c

index 207c248ae0f04a6831d50fc8c34bc732b94d9a7c..bc9166aa9596f7fbe4176a7bf9af4b520de01692 100644 (file)
 #if PHP_HTTP_HAVE_LIBICU
 #      include <unicode/uversion.h>
 #endif
-#if PHP_HTTP_HAVE_LIBIDN2
-#      include <idn2.h>
-#endif
 #if PHP_HTTP_HAVE_LIBIDN
 #      include <idna.h>
 #endif
+#if PHP_HTTP_HAVE_LIBIDN2
+#      include <idn2.h>
+#endif
 #if PHP_HTTP_HAVE_LIBIDNKIT2 || PHP_HTTP_HAVE_LIBIDNKIT
 #include "idn/version.h"
 #endif
index 029e6a8ca37c3cf64a59c06ddb1e280fb7b63239..361e61c514486d5ed9d979e1f9cb0fbeb341dcb3 100644 (file)
 
 #include "php_http_api.h"
 
-#if PHP_HTTP_HAVE_LIBIDN2
-#      include <idn2.h>
-#endif
 #if PHP_HTTP_HAVE_LIBIDN
 #      include <idna.h>
 #endif
+#if PHP_HTTP_HAVE_LIBIDN2
+#      include <idn2.h>
+#endif
 #if PHP_HTTP_HAVE_LIBICU
 #      include <unicode/uidna.h>
 #endif