[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
[gnurl] 120/264: windows: enable UnixSockets with all build toolchains
From: |
gnunet |
Subject: |
[gnurl] 120/264: windows: enable UnixSockets with all build toolchains |
Date: |
Thu, 30 Apr 2020 16:07:03 +0200 |
This is an automated email from the git hooks/post-receive script.
nikita pushed a commit to branch master
in repository gnurl.
commit 23a870f2fd041278762ecf819cd1467019588c58
Author: Viktor Szakats <address@hidden>
AuthorDate: Sat Apr 4 17:49:20 2020 +0000
windows: enable UnixSockets with all build toolchains
Extend existing unix socket support in Windows builds to be
enabled for all toolchain vendors or versions. (Previously
it was only supported with certain MSVC versions + more recent
Windows 10 SDKs)
Ref: https://devblogs.microsoft.com/commandline/af_unix-comes-to-windows/
Ref: https://github.com/curl/curl/issues/5162
Closes: https://github.com/curl/curl/pull/5170
---
lib/config-win32.h | 13 ++++++++-----
lib/curl_addrinfo.c | 6 +-----
2 files changed, 9 insertions(+), 10 deletions(-)
diff --git a/lib/config-win32.h b/lib/config-win32.h
index d19665d71..516baca02 100644
--- a/lib/config-win32.h
+++ b/lib/config-win32.h
@@ -719,12 +719,15 @@ Vista
#endif
/* Define to use Unix sockets. */
-#if defined(_MSC_VER) && (_MSC_VER >= 1500)
-/* sdkddkver.h first shipped with Platform SDK v6.0A included with VS2008 */
-#include <sdkddkver.h>
-#if defined(NTDDI_WIN10_RS4)
#define USE_UNIX_SOCKETS
-#endif
+#if !defined(UNIX_PATH_MAX)
+ /* Replicating logic present in afunix.h of newer Windows 10 SDK versions */
+# define UNIX_PATH_MAX 108
+# include <ws2tcpip.h>
+ typedef struct sockaddr_un {
+ ADDRESS_FAMILY sun_family;
+ char sun_path[UNIX_PATH_MAX];
+ } SOCKADDR_UN, *PSOCKADDR_UN;
#endif
/* ---------------------------------------------------------------- */
diff --git a/lib/curl_addrinfo.c b/lib/curl_addrinfo.c
index 16c4779c1..b2dd83423 100644
--- a/lib/curl_addrinfo.c
+++ b/lib/curl_addrinfo.c
@@ -5,7 +5,7 @@
* | (__| |_| | _ <| |___
* \___|\___/|_| \_\_____|
*
- * Copyright (C) 1998 - 2019, Daniel Stenberg, <address@hidden>, et al.
+ * Copyright (C) 1998 - 2020, Daniel Stenberg, <address@hidden>, et al.
*
* This software is licensed as described in the file COPYING, which
* you should have received as part of this distribution. The terms
@@ -50,10 +50,6 @@
# define in_addr_t unsigned long
#endif
-#if defined(WIN32) && defined(USE_UNIX_SOCKETS)
-#include <afunix.h>
-#endif
-
#include <stddef.h>
#include "curl_addrinfo.h"
--
To stop receiving notification emails like this one, please contact
address@hidden.
- [gnurl] 30/264: vtls: free ssl_config leftovers on out-of-memory, (continued)
- [gnurl] 30/264: vtls: free ssl_config leftovers on out-of-memory, gnunet, 2020/04/30
- [gnurl] 75/264: config: remove all defines of HAVE_DES_H, gnunet, 2020/04/30
- [gnurl] 65/264: test970: improve the test, gnunet, 2020/04/30
- [gnurl] 82/264: docs/make: generate curl.1 from listed files only, gnunet, 2020/04/30
- [gnurl] 76/264: CI: migrate macOS jobs from Azure and Travis CI to GitHub Actions, gnunet, 2020/04/30
- [gnurl] 34/264: DISABLED: disable test 323, gnunet, 2020/04/30
- [gnurl] 42/264: tool_setopt: correct the copyright year range, gnunet, 2020/04/30
- [gnurl] 90/264: KNOWN_BUGS: "stick to same family over SOCKS pro" is presumed fixed, gnunet, 2020/04/30
- [gnurl] 63/264: TODO: Use "random" ports for the test servers, gnunet, 2020/04/30
- [gnurl] 85/264: RELEASE-NOTES: synced, gnunet, 2020/04/30
- [gnurl] 120/264: windows: enable UnixSockets with all build toolchains,
gnunet <=
- [gnurl] 118/264: sockfilt: remove redundancy in timeout handling, gnunet, 2020/04/30
- [gnurl] 97/264: output.d: quote the URL when globbing, gnunet, 2020/04/30
- [gnurl] 15/264: tests: remove python_dependencies for smbserver from our tree, gnunet, 2020/04/30
- [gnurl] 94/264: curl.h: remnove CURL_VERSION_ESNI. Never supported nor documented, gnunet, 2020/04/30
- [gnurl] 96/264: dist: add tests/version-scan.pl to tarball, gnunet, 2020/04/30
- [gnurl] 99/264: ngtcp2: update to git master for the key installation API change, gnunet, 2020/04/30
- [gnurl] 129/264: lib670: use the same Win32 API check as all other lib tests, gnunet, 2020/04/30
- [gnurl] 102/264: cleanup: insert newline after if() conditions, gnunet, 2020/04/30
- [gnurl] 87/264: mailmap: fixup a few author names/fields, gnunet, 2020/04/30
- [gnurl] 86/264: version: add 'cainfo' and 'capath' to version info struct, gnunet, 2020/04/30