From: annalee <150648636+a-n-n-a-l-e-e@users.noreply.github.com> Date: Fri, 29 Dec 2023 05:43:33 +0000 (+0000) Subject: configure: fix no default int compile error in ipv6 detection X-Git-Tag: curl-8_6_0~162 X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=ae75db3527461248b0a7b1686df52200d28d83b9;p=thirdparty%2Fcurl.git configure: fix no default int compile error in ipv6 detection Closes #12607 --- diff --git a/configure.ac b/configure.ac index 3e89da9f32..79c98b3c4e 100644 --- a/configure.ac +++ b/configure.ac @@ -1655,15 +1655,12 @@ AS_HELP_STRING([--disable-ipv6],[Disable IPv6 support]), # include #endif #endif -#include /* for exit() */ -main() + +int main(void) { struct sockaddr_in6 s; (void)s; - if (socket(AF_INET6, SOCK_STREAM, 0) < 0) - exit(1); - else - exit(0); + return socket(AF_INET6, SOCK_STREAM, 0) < 0; } ]]) ],