diff options
| author | NIIBE Yutaka <[email protected]> | 2025-10-21 02:51:49 +0000 |
|---|---|---|
| committer | NIIBE Yutaka <[email protected]> | 2025-10-21 02:51:49 +0000 |
| commit | 61ff3759e827fed5ea47897af1291443aeb5172e (patch) | |
| tree | 6156759636758ab01a45218dda24eb82727a796f /dirmngr/dns-stuff.c | |
| parent | tests:w32: Fix the add-recipeint test for Windows. (diff) | |
| download | gnupg-61ff3759e827fed5ea47897af1291443aeb5172e.tar.gz gnupg-61ff3759e827fed5ea47897af1291443aeb5172e.zip | |
common,dirmngr:w32: Fix for semi-hosted environment.
* common/init.c [HAVE_W32_SYSTEM] (windows_semihosted_by_wine): New.
(_init_common_subsystems): Initialize the variable.
* common/stringhelp.c (change_slashes): Don't change slashes
under semi-hosted environment.
* common/util.h [HAVE_W32_SYSTEM] (windows_semihosted_by_wine): New.
* dirmngr/dns-stuff.c [HAVE_W32_SYSTEM] (check_inet_support): Disable
the check by "..localmachine" under semi-hosted environment.
--
GnuPG-bug-id: 7138
Signed-off-by: NIIBE Yutaka <[email protected]>
Diffstat (limited to 'dirmngr/dns-stuff.c')
| -rw-r--r-- | dirmngr/dns-stuff.c | 7 |
1 files changed, 7 insertions, 0 deletions
diff --git a/dirmngr/dns-stuff.c b/dirmngr/dns-stuff.c index 270717215..4f8fb5f8a 100644 --- a/dirmngr/dns-stuff.c +++ b/dirmngr/dns-stuff.c @@ -2436,6 +2436,12 @@ check_inet_support (int *r_v4, int *r_v6) struct addrinfo *aibuf = NULL; struct addrinfo *ai; + if (windows_semihosted_by_wine) + { + *r_v4 = *r_v6 = 1; + goto leave; + } + ret = getaddrinfo ("..localmachine", NULL, NULL, &aibuf); if (ret) { @@ -2489,6 +2495,7 @@ check_inet_support (int *r_v4, int *r_v6) if (aibuf) freeaddrinfo (aibuf); } + leave: #else /*!HAVE_W32_SYSTEM*/ { /* For now we assume that we have both protocols. */ |
