Book a Demo!
CoCalc Logo Icon
StoreFeaturesDocsShareSupportNewsAboutPoliciesSign UpSign In
sagemathinc
GitHub Repository: sagemathinc/wapython
Path: blob/main/core/openssl/src/patches/00-af-unix.patch
1067 views
1
This is a fix for a bug in the openssl build system. TODO: I will submit an upstream PR.
2
Everywhere else in the source they do #ifdef AF_UNIX, but they missed exactly one spot.
3
4
diff --git a/apps/lib/s_socket.c b/apps/lib/s_socket.c
5
index 059afe4..4b75134 100644
6
--- a/apps/lib/s_socket.c
7
+++ b/apps/lib/s_socket.c
8
@@ -179,7 +179,10 @@ int init_client(int *sock, const char *host, const char *port,
9
BIO_ADDRINFO_family(res) == AF_INET6 ? "IPv6 " :
10
#endif
11
BIO_ADDRINFO_family(res) == AF_INET ? "IPv4 " :
12
- BIO_ADDRINFO_family(res) == AF_UNIX ? "unix " : "",
13
+#ifdef AF_UNIX
14
+ BIO_ADDRINFO_family(res) == AF_UNIX ? "unix " :
15
+#endif
16
+ "",
17
bindhost != NULL ? bindhost : "",
18
bindport != NULL ? ":" : "",
19
bindport != NULL ? bindport : "");
20
21