From 985944cc2f488bce9a13334f3545aa387220aa59 Mon Sep 17 00:00:00 2001 From: "Stephen M. Coakley" Date: Wed, 5 Aug 2020 22:54:22 -0500 Subject: [PATCH] Enable HAVE_GETSOCKNAME for bundled build Define `HAVE_GETSOCKNAME` for bundled curl-sys so that `Easy2::local_ip` and `Easy2::local_port` don't return blank values. We're already enabling `HAVE_GETPEERNAME` and your system probably has `getsockname` if it has `getpeername`. --- curl-sys/build.rs | 1 + 1 file changed, 1 insertion(+) diff --git a/curl-sys/build.rs b/curl-sys/build.rs index ef53e6f3c2..32c8d3a988 100644 --- a/curl-sys/build.rs +++ b/curl-sys/build.rs @@ -202,6 +202,7 @@ fn main() { .file("curl/lib/wildcard.c") .define("HAVE_GETADDRINFO", None) .define("HAVE_GETPEERNAME", None) + .define("HAVE_GETSOCKNAME", None) .warnings(false); if cfg!(feature = "protocol-ftp") {