X-Git-Url: http://git.demorecorder.com/cgi-bin/gitweb.cgi?a=blobdiff_plain;f=src%2Fxcb_util.c;h=3eacc0dab0370dd822561d8ae69ec0d1f9700b12;hb=7a74ba3d0212f9bfe021d6da9070f71cbc53f85b;hp=dd2305abdce258c3967c7d7c8fd17f47aefde9ce;hpb=09045eaac34973662aaa820a94ca8ed66d9dcb4e;p=free-sw%2Fxcb%2Flibxcb diff --git a/src/xcb_util.c b/src/xcb_util.c index dd2305a..3eacc0d 100644 --- a/src/xcb_util.c +++ b/src/xcb_util.c @@ -216,6 +216,7 @@ static int _xcb_open_tcp(char *host, char *protocol, const unsigned short port) if (protocol && strcmp("tcp",protocol)) return -1; +#ifdef AF_INET6 /* Allow IPv6 addresses enclosed in brackets. */ if(host[0] == '[' && (bracket = strrchr(host, ']')) && bracket[1] == '\0') { @@ -224,6 +225,7 @@ static int _xcb_open_tcp(char *host, char *protocol, const unsigned short port) hints.ai_flags |= AI_NUMERICHOST; hints.ai_family = AF_INET6; } +#endif snprintf(service, sizeof(service), "%hu", port); if(getaddrinfo(host, service, &hints, &results))