]> granicus.if.org Git - libevent/commitdiff
Avoid errors in evutil.c when building with _UNICODE defined
authorBrodie Thiesfield <brofield2@jellycan.com>
Mon, 8 Mar 2010 18:46:04 +0000 (13:46 -0500)
committerNick Mathewson <nickm@torproject.org>
Mon, 8 Mar 2010 18:46:04 +0000 (13:46 -0500)
evutil.c

index 7ab47981655eb958d33cd644bbbe49cd7707064a..0be4e0929a2e78a0f1731649dd9e14dd4ad76228 100644 (file)
--- a/evutil.c
+++ b/evutil.c
@@ -1277,7 +1277,9 @@ evutil_gai_strerror(int err)
        case EVUTIL_EAI_SYSTEM:
                return "system error";
        default:
-#ifdef USE_NATIVE_GETADDRINFO
+#if defined(USE_NATIVE_GETADDRINFO) && defined(WIN32)
+               return gai_strerrorA(err);
+#elif defined(USE_NATIVE_GETADDRINFO)
                return gai_strerror(err);
 #else
                return "Unknown error code";