From 8d03ef1615039a4414a99add745cff5103cd617e Mon Sep 17 00:00:00 2001 From: yhirose Date: Fri, 2 Jan 2026 22:28:15 -0500 Subject: [PATCH] Fix #2318 on macOS --- httplib.h | 1 + 1 file changed, 1 insertion(+) diff --git a/httplib.h b/httplib.h index e40e7f6..c69d861 100644 --- a/httplib.h +++ b/httplib.h @@ -4547,6 +4547,7 @@ inline int getaddrinfo_with_timeout(const char *node, const char *service, return ret; #elif TARGET_OS_MAC + if (!node) { return EAI_NONAME; } // macOS implementation using CFHost API for asynchronous DNS resolution CFStringRef hostname_ref = CFStringCreateWithCString( kCFAllocatorDefault, node, kCFStringEncodingUTF8);