1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
|
Only enable AI_IDN if it is actually defined.
Upstream-status: Pending
--- libparistraceroute-0.93.orig/libparistraceroute/address.c
+++ libparistraceroute-0.93/libparistraceroute/address.c
@@ -37,8 +37,6 @@
#endif
-#define AI_IDN 0x0040
-
static void ip_dump(int family, const void * ip, char * buffer, size_t buffer_len) {
if (inet_ntop(family, ip, buffer, buffer_len)) {
printf("%s", buffer);
@@ -58,7 +56,9 @@
// Initialize hints
memset(&hints, 0, sizeof(hints));
hints.ai_family = family;
+#ifdef AI_IDN
hints.ai_flags = AI_IDN;
+#endif
// Convert string hostname / IP into a sequence of addrinfo instances
if ((ret = getaddrinfo(hostname, NULL, &hints, &res)) != 0) {
|