mirror of
https://github.com/curl/curl.git
synced 2026-08-06 11:16:15 +03:00
tidy-up: OS names
Use these words and casing more consistently across text, comments and one curl tool output: AIX, ALPN, ANSI, BSD, Cygwin, Darwin, FreeBSD, GitHub, HP-UX, Linux, macOS, MS-DOS, MSYS, MinGW, NTLM, POSIX, Solaris, UNIX, Unix, Unicode, WINE, WebDAV, Win32, winbind, WinIDN, Windows, Windows CE, Winsock. Mostly OS names and a few more. Also a couple of other minor text fixups. Closes #14360
This commit is contained in:
parent
a4ad7dc5a3
commit
f81f351b9a
146 changed files with 355 additions and 358 deletions
|
|
@ -58,7 +58,7 @@ are configured:
|
|||
|
||||
GitHub Actions runs the following tests:
|
||||
|
||||
- Mac OS tests with a variety of different compilation options
|
||||
- macOS tests with a variety of different compilation options
|
||||
- Fuzz tests ([see the curl-fuzzer repo for more
|
||||
info](https://github.com/curl/curl-fuzzer)).
|
||||
- Curl compiled using the Rust TLS backend with Hyper
|
||||
|
|
|
|||
|
|
@ -152,7 +152,7 @@ Available substitute variables include:
|
|||
- `%NOLISTENPORT` - Port number where no service is listening
|
||||
- `%POP36PORT` - IPv6 port number of the POP3 server
|
||||
- `%POP3PORT` - Port number of the POP3 server
|
||||
- `%POSIX_PWD` - Current directory somewhat mingw friendly
|
||||
- `%POSIX_PWD` - Current directory somewhat MinGW friendly
|
||||
- `%PROXYPORT` - Port number of the HTTP proxy
|
||||
- `%PWD` - Current directory
|
||||
- `%RTSP6PORT` - IPv6 port number of the RTSP server
|
||||
|
|
|
|||
|
|
@ -45,8 +45,8 @@ SPDX-License-Identifier: curl
|
|||
|
||||
## Requires to run
|
||||
|
||||
- perl (and a unix-style shell)
|
||||
- python (and a unix-style shell, for SMB and TELNET tests)
|
||||
- perl (and a Unix-style shell)
|
||||
- python (and a Unix-style shell, for SMB and TELNET tests)
|
||||
- python-impacket (for SMB tests)
|
||||
- diff (when a test fails, a diff is shown)
|
||||
- stunnel (for HTTPS and FTPS tests)
|
||||
|
|
|
|||
|
|
@ -46,11 +46,11 @@
|
|||
# fnmatch differences are just too common to make testing them sensible
|
||||
1307
|
||||
1316
|
||||
# test 1510 causes problems on the CI on github
|
||||
# test 1510 causes problems on the CI on GitHub
|
||||
# example: https://travis-ci.org/curl/curl/builds/81633600
|
||||
1510
|
||||
1512
|
||||
# test 1801 causes problems on Mac OS X and github
|
||||
# test 1801 causes problems on macOS and GitHub
|
||||
# https://github.com/curl/curl/issues/380
|
||||
1801
|
||||
# test 2086 causes issues on Windows only
|
||||
|
|
|
|||
|
|
@ -24,7 +24,7 @@ ftp://%HOSTIP:%FTPPORT/%TESTNUMBER -T %LOGDIR/upload%TESTNUMBER --crlf
|
|||
</command>
|
||||
<file name="%LOGDIR/upload%TESTNUMBER">
|
||||
file
|
||||
with unix newlines
|
||||
with Unix newlines
|
||||
meant to be
|
||||
converted
|
||||
with
|
||||
|
|
@ -46,7 +46,7 @@ QUIT
|
|||
</protocol>
|
||||
<upload>
|
||||
file
|
||||
with unix newlines
|
||||
with Unix newlines
|
||||
meant to be
|
||||
converted
|
||||
with
|
||||
|
|
|
|||
|
|
@ -39,7 +39,7 @@ http
|
|||
socks5unix
|
||||
</server>
|
||||
<name>
|
||||
HTTP GET via SOCKS5 proxy via unix sockets
|
||||
HTTP GET via SOCKS5 proxy via Unix sockets
|
||||
</name>
|
||||
<command>
|
||||
--socks5 localhost%SOCKSUNIXPATH http://%HOSTIP:%HTTPPORT/%TESTNUMBER
|
||||
|
|
|
|||
|
|
@ -40,7 +40,7 @@ http
|
|||
socks5unix
|
||||
</server>
|
||||
<name>
|
||||
HTTP GET with host name using SOCKS5h via unix sockets
|
||||
HTTP GET with host name using SOCKS5h via Unix sockets
|
||||
</name>
|
||||
<command>
|
||||
http://this.is.a.host.name:%HTTPPORT/%TESTNUMBER --proxy socks5h://localhost%SOCKSUNIXPATH
|
||||
|
|
|
|||
|
|
@ -41,7 +41,7 @@ https
|
|||
socks5unix
|
||||
</server>
|
||||
<name>
|
||||
HTTPS GET with host name using SOCKS5h via unix sockets
|
||||
HTTPS GET with host name using SOCKS5h via Unix sockets
|
||||
</name>
|
||||
<command>
|
||||
https://this.is.a.host.name:%HTTPSPORT/%TESTNUMBER -k --proxy socks5h://localhost%SOCKSUNIXPATH
|
||||
|
|
|
|||
|
|
@ -15,7 +15,7 @@ none
|
|||
unittest
|
||||
</features>
|
||||
<name>
|
||||
Test WIN32/MSDOS filename sanitization
|
||||
Test Windows/MS-DOS filename sanitization
|
||||
</name>
|
||||
</client>
|
||||
</testcase>
|
||||
|
|
|
|||
|
|
@ -51,7 +51,7 @@ Nice auth sir!
|
|||
http
|
||||
</server>
|
||||
<name>
|
||||
HTTP Negotiate authentication (stub ntlm)
|
||||
HTTP Negotiate authentication (stub NTLM)
|
||||
</name>
|
||||
<features>
|
||||
GSS-API
|
||||
|
|
|
|||
|
|
@ -21,13 +21,13 @@ moo
|
|||
file
|
||||
</server>
|
||||
<name>
|
||||
file:// with unix path resolution behavior for the case of extra slashes
|
||||
file:// with Unix path resolution behavior for the case of extra slashes
|
||||
</name>
|
||||
<command option="no-include">
|
||||
file:////%PWD/%LOGDIR/test%TESTNUMBER.txt
|
||||
</command>
|
||||
<precheck>
|
||||
perl -e "print 'Test requires a unix system' if ( $^O eq 'MSWin32' || $^O eq 'cygwin' || $^O eq 'dos' || $^O eq 'msys');"
|
||||
perl -e "print 'Test requires a Unix system' if ( $^O eq 'MSWin32' || $^O eq 'cygwin' || $^O eq 'dos' || $^O eq 'msys');"
|
||||
</precheck>
|
||||
<file name="%LOGDIR/test%TESTNUMBER.txt">
|
||||
foo
|
||||
|
|
|
|||
|
|
@ -32,7 +32,7 @@ Funny-head: yesyes
|
|||
http
|
||||
</server>
|
||||
<name>
|
||||
JSON encoding of unicode string
|
||||
JSON encoding of Unicode string
|
||||
</name>
|
||||
<file name="%LOGDIR/junk" nonewline="yes">
|
||||
%hex[%e2%80%9c]hex%
|
||||
|
|
|
|||
|
|
@ -47,7 +47,7 @@ mqtt://%HOSTIP:%MQTTPORT/%TESTNUMBER -m 3
|
|||
<strippart>
|
||||
s/^(.* 00044d5154540402003c000c6375726c).*/$1/
|
||||
</strippart>
|
||||
# on windows the disconnect is never seen - no idea why
|
||||
# on Windows the disconnect is never seen - no idea why
|
||||
<strip>
|
||||
^server DISCONNECT 0 e000
|
||||
</strip>
|
||||
|
|
|
|||
|
|
@ -45,7 +45,7 @@ mqtt://%HOSTIP:%MQTTPORT/%TESTNUMBER --max-filesize 11
|
|||
<strippart>
|
||||
s/^(.* 00044d5154540402003c000c6375726c).*/$1/
|
||||
</strippart>
|
||||
# on windows the disconnect is never seen - no idea why
|
||||
# on Windows the disconnect is never seen - no idea why
|
||||
<strip>
|
||||
^server DISCONNECT 0 e000
|
||||
</strip>
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ Funny-head: yesyes
|
|||
http
|
||||
</server>
|
||||
<name>
|
||||
warn about unicode quote character
|
||||
warn about Unicode quote character
|
||||
</name>
|
||||
<command>
|
||||
-H “host: %HOSTIP:%HTTPPORT/” -s
|
||||
|
|
@ -46,7 +46,7 @@ warn about unicode quote character
|
|||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<stderr>
|
||||
%hex[Warning: The argument '%e2%80%9chost:' starts with a unicode quote where maybe an ]hex%
|
||||
%hex[Warning: The argument '%e2%80%9chost:' starts with a Unicode quote where maybe an ]hex%
|
||||
Warning: ASCII " was intended?
|
||||
</stderr>
|
||||
</verify>
|
||||
|
|
|
|||
|
|
@ -35,7 +35,7 @@ Funny-head: yesyes
|
|||
http
|
||||
</server>
|
||||
<name>
|
||||
warn about unicode quote character read from config file
|
||||
warn about Unicode quote character read from config file
|
||||
</name>
|
||||
<file name="%LOGDIR/input%TESTNUMBER">
|
||||
-H “host:fake”
|
||||
|
|
@ -49,7 +49,7 @@ warn about unicode quote character read from config file
|
|||
# Verify data after the test has been "shot"
|
||||
<verify>
|
||||
<stderr mode="text">
|
||||
%hex[Warning: The argument '%e2%80%9chost:fake%e2%80%9d' starts with a unicode quote where ]hex%
|
||||
%hex[Warning: The argument '%e2%80%9chost:fake%e2%80%9d' starts with a Unicode quote where ]hex%
|
||||
Warning: maybe an ASCII " was intended?
|
||||
</stderr>
|
||||
</verify>
|
||||
|
|
|
|||
|
|
@ -26,7 +26,7 @@ To: another
|
|||
|
||||
email
|
||||
headers and body
|
||||
with unix newlines
|
||||
with Unix newlines
|
||||
meant to be
|
||||
converted
|
||||
with
|
||||
|
|
@ -55,7 +55,7 @@ To: another
|
|||
|
||||
email
|
||||
headers and body
|
||||
with unix newlines
|
||||
with Unix newlines
|
||||
meant to be
|
||||
converted
|
||||
with
|
||||
|
|
|
|||
|
|
@ -226,7 +226,7 @@ sub ftpmsg {
|
|||
|
||||
# use this, open->print->close system only to make the file
|
||||
# open as little as possible, to make the test suite run
|
||||
# better on windows/cygwin
|
||||
# better on Windows/Cygwin
|
||||
}
|
||||
|
||||
#**********************************************************************
|
||||
|
|
|
|||
|
|
@ -316,7 +316,7 @@ sub compareparts {
|
|||
|
||||
# NOTE: this no longer strips off carriage returns from the arrays. Is that
|
||||
# really necessary? It ruins the testing of newlines. I believe it was once
|
||||
# added to enable tests on win32.
|
||||
# added to enable tests on Windows.
|
||||
|
||||
if($first ne $second) {
|
||||
return 1;
|
||||
|
|
@ -332,7 +332,7 @@ sub writearray {
|
|||
my ($filename, $arrayref)=@_;
|
||||
|
||||
open(my $temp, ">", "$filename") || die "Failure writing file";
|
||||
binmode($temp,":raw"); # cygwin fix by Kevin Roth
|
||||
binmode($temp,":raw"); # Cygwin fix by Kevin Roth
|
||||
for(@$arrayref) {
|
||||
print $temp $_;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@
|
|||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
/* somewhat unix-specific */
|
||||
/* somewhat Unix-specific */
|
||||
#include <sys/time.h>
|
||||
#include <unistd.h>
|
||||
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@
|
|||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
/* somewhat unix-specific */
|
||||
/* somewhat Unix-specific */
|
||||
#include <sys/time.h>
|
||||
#include <unistd.h>
|
||||
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@
|
|||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
/* somewhat unix-specific */
|
||||
/* somewhat Unix-specific */
|
||||
#include <sys/time.h>
|
||||
#include <unistd.h>
|
||||
|
||||
|
|
|
|||
|
|
@ -34,7 +34,7 @@
|
|||
#include <stdlib.h>
|
||||
#include <string.h>
|
||||
|
||||
/* somewhat unix-specific */
|
||||
/* somewhat Unix-specific */
|
||||
#include <sys/time.h>
|
||||
#include <unistd.h>
|
||||
|
||||
|
|
|
|||
|
|
@ -95,7 +95,7 @@ class TestUnix:
|
|||
yield faker
|
||||
faker.stop()
|
||||
|
||||
# download http: via unix socket
|
||||
# download http: via Unix socket
|
||||
def test_11_01_unix_connect_http(self, env: Env, httpd, uds_faker, repeat):
|
||||
curl = CurlClient(env=env)
|
||||
url = f'http://{env.domain1}:{env.http_port}/data.json'
|
||||
|
|
@ -105,7 +105,7 @@ class TestUnix:
|
|||
])
|
||||
r.check_response(count=1, http_status=200)
|
||||
|
||||
# download https: via unix socket
|
||||
# download https: via Unix socket
|
||||
@pytest.mark.skipif(condition=not Env.have_ssl_curl(), reason=f"curl without SSL")
|
||||
def test_11_02_unix_connect_http(self, env: Env, httpd, uds_faker, repeat):
|
||||
curl = CurlClient(env=env)
|
||||
|
|
@ -116,7 +116,7 @@ class TestUnix:
|
|||
])
|
||||
r.check_response(exitcode=35, http_status=None)
|
||||
|
||||
# download HTTP/3 via unix socket
|
||||
# download HTTP/3 via Unix socket
|
||||
@pytest.mark.skipif(condition=not Env.have_h3(), reason='h3 not supported')
|
||||
def test_11_03_unix_connect_quic(self, env: Env, httpd, uds_faker, repeat):
|
||||
curl = CurlClient(env=env)
|
||||
|
|
|
|||
|
|
@ -23,20 +23,20 @@
|
|||
###########################################################################
|
||||
|
||||
# This Perl package helps with path transforming when running curl tests on
|
||||
# Win32 platform with Msys or Cygwin.
|
||||
# Windows platform with MSYS or Cygwin.
|
||||
# Three main functions 'sys_native_abs_path', 'sys_native_path' and
|
||||
# 'build_sys_abs_path' autodetect format of given pathnames. Following formats
|
||||
# are supported:
|
||||
# (1) /some/path - absolute path in Unix-style
|
||||
# (2) D:/some/path - absolute path in Win32-style
|
||||
# (2) D:/some/path - absolute path in Windows-style
|
||||
# (3) some/path - relative path
|
||||
# (4) D:some/path - path relative to current directory on Win32 drive (paths
|
||||
# like 'D:' are treated as 'D:./') (*)
|
||||
# (5) \some/path - path from root directory on current Win32 drive (*)
|
||||
# (4) D:some/path - path relative to current directory on Windows drive
|
||||
# (paths like 'D:' are treated as 'D:./') (*)
|
||||
# (5) \some/path - path from root directory on current Windows drive (*)
|
||||
# All forward '/' and back '\' slashes are treated identically except leading
|
||||
# slash in forms (1) and (5).
|
||||
# Forward slashes are simpler processed in Perl, do not require extra escaping
|
||||
# for shell (unlike back slashes) and accepted by Win32 native programs, so
|
||||
# for shell (unlike back slashes) and accepted by Windows native programs, so
|
||||
# all functions return paths with only forward slashes except
|
||||
# 'sys_native_path' which returns paths with first forward slash for form (5).
|
||||
# All returned paths don't contain any duplicated slashes, only single slashes
|
||||
|
|
@ -46,8 +46,9 @@
|
|||
# so all functions can be unconditionally used on all platforms.
|
||||
#
|
||||
# (*) CAUTION! Forms (4) and (5) are not recommended to use as they can be
|
||||
# interpreted incorrectly in Perl and Msys/Cygwin environment have low
|
||||
# control on Win32 current drive and Win32 current path on specific drive.
|
||||
# interpreted incorrectly in Perl and MSYS/Cygwin environment have low
|
||||
# control on Windows current drive and Windows current path on specific
|
||||
# drive.
|
||||
|
||||
package pathhelp;
|
||||
|
||||
|
|
@ -88,7 +89,7 @@ BEGIN {
|
|||
# Cached static variable, Perl 5.0-compatible.
|
||||
my $cygdrive_present;
|
||||
|
||||
# Returns boolean true if Win32 drives mounted with '/cygdrive/' prefix.
|
||||
# Returns boolean true if Windows drives mounted with '/cygdrive/' prefix.
|
||||
sub drives_mounted_on_cygdrive {
|
||||
return $cygdrive_present if defined $cygdrive_present;
|
||||
$cygdrive_present = ((-e '/cygdrive/') && (-d '/cygdrive/')) ? 1 : 0;
|
||||
|
|
@ -96,7 +97,7 @@ BEGIN {
|
|||
}
|
||||
}
|
||||
|
||||
my $use_cygpath; # Only for Win32:
|
||||
my $use_cygpath; # Only for Windows:
|
||||
# undef - autodetect
|
||||
# 0 - do not use cygpath
|
||||
# 1 - use cygpath
|
||||
|
|
@ -123,17 +124,17 @@ sub should_use_cygpath {
|
|||
sub normalize_path;
|
||||
|
||||
#######################################################################
|
||||
# Returns current working directory in Win32 format on Windows.
|
||||
# Returns current working directory in Windows format on Windows.
|
||||
#
|
||||
sub sys_native_current_path {
|
||||
return Cwd::getcwd() if !os_is_win();
|
||||
|
||||
my $cur_dir;
|
||||
if($^O eq 'msys') {
|
||||
# MSys shell has built-in command.
|
||||
# MSYS shell has built-in command.
|
||||
chomp($cur_dir = `bash -c 'pwd -W'`);
|
||||
if($? != 0) {
|
||||
warn "Can't determine Win32 current directory.\n";
|
||||
warn "Can't determine Windows current directory.\n";
|
||||
return undef;
|
||||
}
|
||||
# Add final slash if required.
|
||||
|
|
@ -143,7 +144,7 @@ sub sys_native_current_path {
|
|||
# Do not use 'cygpath' - it falsely succeed on paths like '/cygdrive'.
|
||||
$cur_dir = `cmd "/c;" echo %__CD__%`;
|
||||
if($? != 0 || substr($cur_dir, 0, 1) eq '%') {
|
||||
warn "Can't determine Win32 current directory.\n";
|
||||
warn "Can't determine Windows current directory.\n";
|
||||
return undef;
|
||||
}
|
||||
# Remove both '\r' and '\n'.
|
||||
|
|
@ -156,30 +157,30 @@ sub sys_native_current_path {
|
|||
}
|
||||
|
||||
#######################################################################
|
||||
# Returns Win32 current drive letter with colon.
|
||||
# Returns Windows current drive letter with colon.
|
||||
#
|
||||
sub get_win32_current_drive {
|
||||
# Notice parameter "/c;" - it's required to turn off Msys's
|
||||
# Notice parameter "/c;" - it's required to turn off MSYS's
|
||||
# transformation of '/c' and compatible with Cygwin.
|
||||
my $drive_letter = `cmd "/c;" echo %__CD__:~0,2%`;
|
||||
if($? != 0 || substr($drive_letter, 1, 1) ne ':') {
|
||||
warn "Can't determine current Win32 drive letter.\n";
|
||||
warn "Can't determine current Windows drive letter.\n";
|
||||
return undef;
|
||||
}
|
||||
|
||||
return substr($drive_letter, 0, 2);
|
||||
}
|
||||
|
||||
# Internal function. Converts path by using Msys's built-in transformation.
|
||||
# Internal function. Converts path by using MSYS's built-in transformation.
|
||||
# Returned path may contain duplicated and back slashes.
|
||||
sub do_msys_transform;
|
||||
|
||||
# Internal function. Gets two parameters: first parameter must be single
|
||||
# drive letter ('c'), second optional parameter is path relative to drive's
|
||||
# current working directory. Returns Win32 absolute normalized path.
|
||||
# current working directory. Returns Windows absolute normalized path.
|
||||
sub get_abs_path_on_win32_drive;
|
||||
|
||||
# Internal function. Tries to find or guess Win32 version of given
|
||||
# Internal function. Tries to find or guess Windows version of given
|
||||
# absolute Unix-style path. Other types of paths are not supported.
|
||||
# Returned paths contain only single forward slashes (no back and
|
||||
# duplicated slashes).
|
||||
|
|
@ -187,7 +188,7 @@ sub get_abs_path_on_win32_drive;
|
|||
sub do_dumb_guessed_transform;
|
||||
|
||||
#######################################################################
|
||||
# Converts given path to system native format, i.e. to Win32 format on
|
||||
# Converts given path to system native format, i.e. to Windows format on
|
||||
# Windows platform. Relative paths converted to relative, absolute
|
||||
# paths converted to absolute.
|
||||
#
|
||||
|
|
@ -210,12 +211,12 @@ sub sys_native_path {
|
|||
return $path;
|
||||
}
|
||||
elsif($path =~ m{^\\} || $path =~ m{^[a-zA-Z]:[^/\\]}) {
|
||||
# Path is a directory or filename on Win32 current drive or relative
|
||||
# path on current directory on specific Win32 drive.
|
||||
# Path is a directory or filename on Windows current drive or relative
|
||||
# path on current directory on specific Windows drive.
|
||||
# ('\path' or 'D:path')
|
||||
# First type of paths is not processed by Msys transformation and
|
||||
# First type of paths is not processed by MSYS transformation and
|
||||
# resolved to absolute path by 'cygpath'.
|
||||
# Second type is not processed by Msys transformation and may be
|
||||
# Second type is not processed by MSYS transformation and may be
|
||||
# incorrectly processed by 'cygpath' (for paths like 'D:..\../.\')
|
||||
|
||||
my $first_char = ucfirst(substr($path, 0, 1));
|
||||
|
|
@ -224,7 +225,7 @@ sub sys_native_path {
|
|||
$path =~ s{[\\/]+}{/}g;
|
||||
|
||||
# Convert leading slash back to forward slash to indicate
|
||||
# directory on Win32 current drive or capitalize drive letter.
|
||||
# directory on Windows current drive or capitalize drive letter.
|
||||
substr($path, 0, 1, $first_char);
|
||||
return $path;
|
||||
}
|
||||
|
|
@ -237,7 +238,7 @@ sub sys_native_path {
|
|||
|
||||
my $has_final_slash = ($path =~ m{[/\\]$});
|
||||
|
||||
# Use 'cygpath', '-m' means Win32 path with forward slashes.
|
||||
# Use 'cygpath', '-m' means Windows path with forward slashes.
|
||||
chomp($path = `cygpath -m '$path'`);
|
||||
if ($? != 0) {
|
||||
warn "Can't convert path by \"cygpath\".\n";
|
||||
|
|
@ -254,13 +255,13 @@ sub sys_native_path {
|
|||
return $path;
|
||||
}
|
||||
elsif($^O eq 'msys') {
|
||||
# Msys transforms automatically path to Windows native form in staring
|
||||
# program parameters if program is not Msys-based.
|
||||
# MSYS transforms automatically path to Windows native form in staring
|
||||
# program parameters if program is not MSYS-based.
|
||||
|
||||
$path = do_msys_transform($path);
|
||||
return undef if !defined $path;
|
||||
|
||||
# Capitalize drive letter for Win32 paths.
|
||||
# Capitalize drive letter for Windows paths.
|
||||
$path =~ s{^([a-z]:)}{\u$1};
|
||||
|
||||
# Replace any back and duplicated slashes with single forward slashes.
|
||||
|
|
@ -268,7 +269,7 @@ sub sys_native_path {
|
|||
return $path;
|
||||
}
|
||||
elsif($path =~ s{^([a-zA-Z]):[/\\]}{\u$1:/}) {
|
||||
# Path is already in Win32 form. ('C:\path')
|
||||
# Path is already in Windows form. ('C:\path')
|
||||
|
||||
# Replace any back and duplicated slashes with single forward slashes.
|
||||
$path =~ s{[\\/]+}{/}g;
|
||||
|
|
@ -282,13 +283,13 @@ sub sys_native_path {
|
|||
return $path;
|
||||
}
|
||||
|
||||
# OS is Windows, but not Msys, path is absolute, path is not in Win32
|
||||
# OS is Windows, but not MSYS, path is absolute, path is not in Windows
|
||||
# form and 'cygpath' is not available.
|
||||
return do_dumb_guessed_transform($path);
|
||||
}
|
||||
|
||||
#######################################################################
|
||||
# Converts given path to system native absolute path, i.e. to Win32
|
||||
# Converts given path to system native absolute path, i.e. to Windows
|
||||
# absolute format on Windows platform. Both relative and absolute
|
||||
# formats are supported for input.
|
||||
#
|
||||
|
|
@ -304,7 +305,7 @@ sub sys_native_abs_path {
|
|||
}
|
||||
|
||||
if($path =~ m{^([a-zA-Z]):($|[^/\\].*$)}) {
|
||||
# Path is single drive with colon or relative path on Win32 drive.
|
||||
# Path is single drive with colon or relative path on Windows drive.
|
||||
# ('C:' or 'C:path')
|
||||
# This kind of relative path is not processed correctly by 'cygpath'.
|
||||
# Get specified drive letter
|
||||
|
|
@ -326,7 +327,7 @@ sub sys_native_abs_path {
|
|||
$path =~ s{^([\\/])[\\/]+}{$1}g;
|
||||
|
||||
print "Inter result: \"$path\"\n";
|
||||
# Use 'cygpath', '-m' means Win32 path with forward slashes,
|
||||
# Use 'cygpath', '-m' means Windows path with forward slashes,
|
||||
# '-a' means absolute path
|
||||
chomp($path = `cygpath -m -a '$path'`);
|
||||
if($? != 0) {
|
||||
|
|
@ -344,14 +345,14 @@ sub sys_native_abs_path {
|
|||
return $path
|
||||
}
|
||||
elsif($path =~ s{^([a-zA-Z]):[/\\]}{\u$1:/}) {
|
||||
# Path is already in Win32 form. ('C:\path')
|
||||
# Path is already in Windows form. ('C:\path')
|
||||
|
||||
# Replace any possible back slashes with forward slashes,
|
||||
# remove any duplicated slashes, resolve relative dirs.
|
||||
return normalize_path($path);
|
||||
}
|
||||
elsif(substr($path, 0, 1) eq '\\' ) {
|
||||
# Path is directory or filename on Win32 current drive. ('\Windows')
|
||||
# Path is directory or filename on Windows current drive. ('\Windows')
|
||||
|
||||
my $w32drive = get_win32_current_drive();
|
||||
return undef if !defined $w32drive;
|
||||
|
|
@ -364,11 +365,11 @@ sub sys_native_abs_path {
|
|||
|
||||
if(substr($path, 0, 1) ne '/') {
|
||||
# Path is in relative form. Resolve relative directories in Unix form
|
||||
# *BEFORE* converting to Win32 form otherwise paths like
|
||||
# *BEFORE* converting to Windows form otherwise paths like
|
||||
# '../../../cygdrive/c/windows' will not be resolved.
|
||||
|
||||
my $cur_dir;
|
||||
# MSys shell has built-in command.
|
||||
# MSYS shell has built-in command.
|
||||
if($^O eq 'msys') {
|
||||
$cur_dir = `bash -c 'pwd -L'`;
|
||||
}
|
||||
|
|
@ -389,8 +390,8 @@ sub sys_native_abs_path {
|
|||
return undef unless defined $path;
|
||||
|
||||
if($^O eq 'msys') {
|
||||
# Msys transforms automatically path to Windows native form in staring
|
||||
# program parameters if program is not Msys-based.
|
||||
# MSYS transforms automatically path to Windows native form in staring
|
||||
# program parameters if program is not MSYS-based.
|
||||
$path = do_msys_transform($path);
|
||||
return undef if !defined $path;
|
||||
|
||||
|
|
@ -398,18 +399,18 @@ sub sys_native_abs_path {
|
|||
$path =~ s{[\\/]+}{/}g;
|
||||
return $path;
|
||||
}
|
||||
# OS is Windows, but not Msys, path is absolute, path is not in Win32
|
||||
# OS is Windows, but not MSYS, path is absolute, path is not in Windows
|
||||
# form and 'cygpath' is not available.
|
||||
|
||||
return do_dumb_guessed_transform($path);
|
||||
}
|
||||
|
||||
# Internal function. Converts given Unix-style absolute path to Win32 format.
|
||||
# Internal function. Converts given Unix-style absolute path to Windows format.
|
||||
sub simple_transform_win32_to_unix;
|
||||
|
||||
#######################################################################
|
||||
# Converts given path to build system format absolute path, i.e. to
|
||||
# Msys/Cygwin Unix-style absolute format on Windows platform. Both
|
||||
# MSYS/Cygwin Unix-style absolute format on Windows platform. Both
|
||||
# relative and absolute formats are supported for input.
|
||||
#
|
||||
sub build_sys_abs_path {
|
||||
|
|
@ -424,12 +425,12 @@ sub build_sys_abs_path {
|
|||
}
|
||||
|
||||
if($path =~ m{^([a-zA-Z]):($|[^/\\].*$)}) {
|
||||
# Path is single drive with colon or relative path on Win32 drive.
|
||||
# Path is single drive with colon or relative path on Windows drive.
|
||||
# ('C:' or 'C:path')
|
||||
# This kind of relative path is not processed correctly by 'cygpath'.
|
||||
# Get specified drive letter
|
||||
|
||||
# Resolve relative dirs in Win32-style path or paths like 'D:/../c/'
|
||||
# Resolve relative dirs in Windows-style path or paths like 'D:/../c/'
|
||||
# will be resolved incorrectly.
|
||||
# Replace any possible back slashes with forward slashes,
|
||||
# remove any duplicated slashes.
|
||||
|
|
@ -442,7 +443,7 @@ sub build_sys_abs_path {
|
|||
# Path is empty string. Return current directory.
|
||||
# Empty string processed correctly by 'cygpath'.
|
||||
|
||||
# MSys shell has built-in command.
|
||||
# MSYS shell has built-in command.
|
||||
if($^O eq 'msys') {
|
||||
chomp($path = `bash -c 'pwd -L'`);
|
||||
}
|
||||
|
|
@ -477,7 +478,7 @@ sub build_sys_abs_path {
|
|||
return undef;
|
||||
}
|
||||
|
||||
# 'cygpath' removes last slash if path is root dir on Win32 drive.
|
||||
# 'cygpath' removes last slash if path is root dir on Windows drive.
|
||||
# Restore it.
|
||||
$path .= '/' if($has_final_slash &&
|
||||
substr($path, length($path) - 1, 1) ne '/');
|
||||
|
|
@ -485,9 +486,9 @@ sub build_sys_abs_path {
|
|||
return $path
|
||||
}
|
||||
elsif($path =~ m{^[a-zA-Z]:[/\\]}) {
|
||||
# Path is already in Win32 form. ('C:\path')
|
||||
# Path is already in Windows form. ('C:\path')
|
||||
|
||||
# Resolve relative dirs in Win32-style path otherwise paths
|
||||
# Resolve relative dirs in Windows-style path otherwise paths
|
||||
# like 'D:/../c/' will be resolved incorrectly.
|
||||
# Replace any possible back slashes with forward slashes,
|
||||
# remove any duplicated slashes.
|
||||
|
|
@ -497,13 +498,13 @@ sub build_sys_abs_path {
|
|||
return simple_transform_win32_to_unix($path);
|
||||
}
|
||||
elsif(substr($path, 0, 1) eq '\\') {
|
||||
# Path is directory or filename on Win32 current drive. ('\Windows')
|
||||
# Path is directory or filename on Windows current drive. ('\Windows')
|
||||
|
||||
my $w32drive = get_win32_current_drive();
|
||||
return undef if !defined $w32drive;
|
||||
|
||||
# Combine drive and path.
|
||||
# Resolve relative dirs in Win32-style path or paths like 'D:/../c/'
|
||||
# Resolve relative dirs in Windows-style path or paths like 'D:/../c/'
|
||||
# will be resolved incorrectly.
|
||||
# Replace any possible back slashes with forward slashes,
|
||||
# remove any duplicated slashes.
|
||||
|
|
@ -513,14 +514,14 @@ sub build_sys_abs_path {
|
|||
return simple_transform_win32_to_unix($path);
|
||||
}
|
||||
|
||||
# Path is not in any Win32 form.
|
||||
# Path is not in any Windows form.
|
||||
if(substr($path, 0, 1) ne '/') {
|
||||
# Path in relative form. Resolve relative directories in Unix form
|
||||
# *BEFORE* converting to Win32 form otherwise paths like
|
||||
# *BEFORE* converting to Windows form otherwise paths like
|
||||
# '../../../cygdrive/c/windows' will not be resolved.
|
||||
|
||||
my $cur_dir;
|
||||
# MSys shell has built-in command.
|
||||
# MSYS shell has built-in command.
|
||||
if($^O eq 'msys') {
|
||||
$cur_dir = `bash -c 'pwd -L'`;
|
||||
}
|
||||
|
|
@ -566,7 +567,7 @@ sub normalize_path {
|
|||
my $prefix;
|
||||
my $have_root = 0;
|
||||
|
||||
# Check whether path starts from Win32 drive. ('C:path' or 'C:\path')
|
||||
# Check whether path starts from Windows drive. ('C:path' or 'C:\path')
|
||||
if($path =~ m{^([a-zA-Z]:(/|\\)?)(.*$)}) {
|
||||
$prefix = $1;
|
||||
$have_root = 1 if defined $2;
|
||||
|
|
@ -611,23 +612,23 @@ sub normalize_path {
|
|||
return $ret;
|
||||
}
|
||||
|
||||
# Internal function. Converts path by using Msys's built-in
|
||||
# Internal function. Converts path by using MSYS's built-in
|
||||
# transformation.
|
||||
sub do_msys_transform {
|
||||
my ($path) = @_;
|
||||
return undef if $^O ne 'msys';
|
||||
return $path if $path eq '';
|
||||
|
||||
# Remove leading double forward slashes, as they turn off Msys
|
||||
# Remove leading double forward slashes, as they turn off MSYS
|
||||
# transforming.
|
||||
$path =~ s{^/[/\\]+}{/};
|
||||
|
||||
# Msys transforms automatically path to Windows native form in staring
|
||||
# program parameters if program is not Msys-based.
|
||||
# MSYS transforms automatically path to Windows native form in staring
|
||||
# program parameters if program is not MSYS-based.
|
||||
# Note: already checked that $path is non-empty.
|
||||
$path = `cmd //c echo '$path'`;
|
||||
if($? != 0) {
|
||||
warn "Can't transform path into Win32 form by using Msys" .
|
||||
warn "Can't transform path into Windows form by using MSYS" .
|
||||
"internal transformation.\n";
|
||||
return undef;
|
||||
}
|
||||
|
|
@ -641,16 +642,16 @@ sub do_msys_transform {
|
|||
|
||||
# Internal function. Gets two parameters: first parameter must be single
|
||||
# drive letter ('c'), second optional parameter is path relative to drive's
|
||||
# current working directory. Returns Win32 absolute normalized path.
|
||||
# current working directory. Returns Windows absolute normalized path.
|
||||
sub get_abs_path_on_win32_drive {
|
||||
my ($drv, $rel_path) = @_;
|
||||
my $res;
|
||||
|
||||
# Get current directory on specified drive.
|
||||
# "/c;" is compatible with both Msys and Cygwin.
|
||||
# "/c;" is compatible with both MSYS and Cygwin.
|
||||
my $cur_dir_on_drv = `cmd "/c;" echo %=$drv:%`;
|
||||
if($? != 0) {
|
||||
warn "Can't determine Win32 current directory on drive $drv:.\n";
|
||||
warn "Can't determine Windows current directory on drive $drv:.\n";
|
||||
return undef;
|
||||
}
|
||||
|
||||
|
|
@ -675,7 +676,7 @@ sub get_abs_path_on_win32_drive {
|
|||
return normalize_path($res);
|
||||
}
|
||||
|
||||
# Internal function. Tries to find or guess Win32 version of given
|
||||
# Internal function. Tries to find or guess Windows version of given
|
||||
# absolute Unix-style path. Other types of paths are not supported.
|
||||
# Returned paths contain only single forward slashes (no back and
|
||||
# duplicated slashes).
|
||||
|
|
@ -690,13 +691,13 @@ sub do_dumb_guessed_transform {
|
|||
# Empty path is not valid.
|
||||
return undef if (length($path) == 0);
|
||||
|
||||
# RE to find Win32 drive letter
|
||||
# RE to find Windows drive letter
|
||||
my $drv_ltr_re = drives_mounted_on_cygdrive() ?
|
||||
qr{^/cygdrive/([a-zA-Z])($|/.*$)} :
|
||||
qr{^/([a-zA-Z])($|/.*$)};
|
||||
|
||||
# Check path whether path is Win32 directly mapped drive and try to
|
||||
# transform it assuming that drive letter is matched to Win32 drive letter.
|
||||
# Check path whether path is Windows directly mapped drive and try to
|
||||
# transform it assuming that drive letter is matched to Windows drive letter.
|
||||
if($path =~ m{$drv_ltr_re}) {
|
||||
return ucfirst($1) . ':/' if(length($2) == 0);
|
||||
return ucfirst($1) . ':' . $2;
|
||||
|
|
@ -736,14 +737,14 @@ sub do_dumb_guessed_transform {
|
|||
else {
|
||||
# Shouldn't happens as root '/' directory should always
|
||||
# be resolvable.
|
||||
warn "Can't determine Win32 directory for path \"$path\".\n";
|
||||
warn "Can't determine Windows directory for path \"$path\".\n";
|
||||
return undef;
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
# Internal function. Converts given Unix-style absolute path to Win32 format.
|
||||
# Internal function. Converts given Unix-style absolute path to Windows format.
|
||||
sub simple_transform_win32_to_unix {
|
||||
my ($path) = @_;
|
||||
|
||||
|
|
@ -752,12 +753,12 @@ sub simple_transform_win32_to_unix {
|
|||
my $res;
|
||||
chomp($res = `cygpath -a -u '$path'`);
|
||||
if($? != 0) {
|
||||
warn "Can't determine Unix-style directory for Win32 " .
|
||||
warn "Can't determine Unix-style directory for Windows " .
|
||||
"directory \"$path\".\n";
|
||||
return undef;
|
||||
}
|
||||
|
||||
# 'cygpath' removes last slash if path is root dir on Win32 drive.
|
||||
# 'cygpath' removes last slash if path is root dir on Windows drive.
|
||||
$res .= '/' if(substr($res, length($res) - 1, 1) ne '/' &&
|
||||
$path =~ m{[/\\]$});
|
||||
return $res;
|
||||
|
|
@ -765,7 +766,7 @@ sub simple_transform_win32_to_unix {
|
|||
|
||||
# 'cygpath' is not available, use guessed transformation.
|
||||
if($path !~ s{^([a-zA-Z]):(?:/|\\)}{/\l$1/}) {
|
||||
warn "Can't determine Unix-style directory for Win32 " .
|
||||
warn "Can't determine Unix-style directory for Windows " .
|
||||
"directory \"$path\".\n";
|
||||
return undef;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -48,7 +48,7 @@ BEGIN {
|
|||
no warnings "all";
|
||||
require Time::HiRes;
|
||||
};
|
||||
# portable sleeping falls back to native Sleep on Win32
|
||||
# portable sleeping falls back to native Sleep on Windows
|
||||
eval {
|
||||
no warnings "all";
|
||||
require Win32;
|
||||
|
|
|
|||
|
|
@ -535,7 +535,7 @@ sub checksystemfeatures {
|
|||
}
|
||||
if($curl =~ /win32|Windows|mingw(32|64)/) {
|
||||
# This is a Windows MinGW build or native build, we need to use
|
||||
# Win32-style path.
|
||||
# Windows-style path.
|
||||
$pwd = sys_native_current_path();
|
||||
$has_textaware = 1;
|
||||
$feature{"win32"} = 1;
|
||||
|
|
@ -682,7 +682,7 @@ sub checksystemfeatures {
|
|||
# 'https-proxy' is used as "server" so consider it a protocol
|
||||
push @protocols, 'https-proxy';
|
||||
}
|
||||
# UNICODE support
|
||||
# Unicode support
|
||||
$feature{"Unicode"} = $feat =~ /Unicode/i;
|
||||
# Thread-safe init
|
||||
$feature{"threadsafe"} = $feat =~ /threadsafe/i;
|
||||
|
|
@ -1245,7 +1245,7 @@ sub singletest_check {
|
|||
# get the mode attribute
|
||||
my $filemode=$hash{'mode'};
|
||||
if($filemode && ($filemode eq "text") && $has_textaware) {
|
||||
# text mode when running on windows: fix line endings
|
||||
# text mode when running on Windows: fix line endings
|
||||
s/\r\n/\n/g for @validstdout;
|
||||
s/\n/\r\n/g for @validstdout;
|
||||
s/\r\n/\n/g for @actual;
|
||||
|
|
@ -1305,7 +1305,7 @@ sub singletest_check {
|
|||
s/\r\n/\n/g for @validstderr;
|
||||
}
|
||||
if($filemode && ($filemode eq "text") && $has_textaware) {
|
||||
# text mode when running on windows: fix line endings
|
||||
# text mode when running on Windows: fix line endings
|
||||
s/\r\n/\n/g for @validstderr;
|
||||
s/\n/\r\n/g for @validstderr;
|
||||
}
|
||||
|
|
@ -1400,7 +1400,7 @@ sub singletest_check {
|
|||
# get the mode attribute
|
||||
my $filemode=$replycheckpartattr{'mode'};
|
||||
if($filemode && ($filemode eq "text") && $has_textaware) {
|
||||
# text mode when running on windows: fix line endings
|
||||
# text mode when running on Windows: fix line endings
|
||||
s/\r\n/\n/g for @replycheckpart;
|
||||
s/\n/\r\n/g for @replycheckpart;
|
||||
}
|
||||
|
|
@ -1430,7 +1430,7 @@ sub singletest_check {
|
|||
# get the mode attribute
|
||||
my $filemode=$replyattr{'mode'};
|
||||
if($filemode && ($filemode eq "text") && $has_textaware) {
|
||||
# text mode when running on windows: fix line endings
|
||||
# text mode when running on Windows: fix line endings
|
||||
s/\r\n/\n/g for @reply;
|
||||
s/\n/\r\n/g for @reply;
|
||||
}
|
||||
|
|
@ -1569,7 +1569,7 @@ sub singletest_check {
|
|||
|
||||
my $filemode=$hash{'mode'};
|
||||
if($filemode && ($filemode eq "text") && $has_textaware) {
|
||||
# text mode when running on windows: fix line endings
|
||||
# text mode when running on Windows: fix line endings
|
||||
s/\r\n/\n/g for @outfile;
|
||||
s/\n/\r\n/g for @outfile;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -243,7 +243,7 @@ if($stunnel_version < 310) {
|
|||
if($stunnel =~ /tstunnel(\.exe)?$/) {
|
||||
$tstunnel_windows = 1;
|
||||
|
||||
# convert Cygwin/MinGW paths to Win32 format
|
||||
# convert Cygwin/MinGW paths to Windows format
|
||||
$capath = pathhelp::sys_native_abs_path($capath);
|
||||
$certfile = pathhelp::sys_native_abs_path($certfile);
|
||||
}
|
||||
|
|
|
|||
|
|
@ -38,7 +38,7 @@
|
|||
#include <netinet/in.h>
|
||||
#endif
|
||||
#ifdef _XOPEN_SOURCE_EXTENDED
|
||||
/* This define is "almost" required to build on HPUX 11 */
|
||||
/* This define is "almost" required to build on HP-UX 11 */
|
||||
#include <arpa/inet.h>
|
||||
#endif
|
||||
#ifdef HAVE_NETDB_H
|
||||
|
|
|
|||
|
|
@ -106,7 +106,7 @@ struct httprequest {
|
|||
bool auth; /* Authorization header present in the incoming request */
|
||||
size_t cl; /* Content-Length of the incoming request */
|
||||
bool digest; /* Authorization digest header found */
|
||||
bool ntlm; /* Authorization ntlm header found */
|
||||
bool ntlm; /* Authorization NTLM header found */
|
||||
int pipe; /* if non-zero, expect this many requests to do a "piped"
|
||||
request/response */
|
||||
int skip; /* if non-zero, the server is instructed to not read this
|
||||
|
|
|
|||
|
|
@ -422,11 +422,11 @@ static bool read_data_block(unsigned char *buffer, ssize_t maxlen,
|
|||
|
||||
#if defined(USE_WINSOCK) && !defined(CURL_WINDOWS_APP)
|
||||
/*
|
||||
* WinSock select() does not support standard file descriptors,
|
||||
* Winsock select() does not support standard file descriptors,
|
||||
* it can only check SOCKETs. The following function is an attempt
|
||||
* to re-create a select() function with support for other handle types.
|
||||
*
|
||||
* select() function with support for WINSOCK2 sockets and all
|
||||
* select() function with support for Winsock2 sockets and all
|
||||
* other handle types supported by WaitForMultipleObjectsEx() as
|
||||
* well as disk files, anonymous and names pipes, and character input.
|
||||
*
|
||||
|
|
@ -683,7 +683,7 @@ static int select_ws(int nfds, fd_set *readfds, fd_set *writefds,
|
|||
/* loop over the handles in the input descriptor sets */
|
||||
nfd = 0; /* number of handled file descriptors */
|
||||
nth = 0; /* number of internal waiting threads */
|
||||
nws = 0; /* number of handled WINSOCK sockets */
|
||||
nws = 0; /* number of handled Winsock sockets */
|
||||
for(fd = 0; fd < nfds; fd++) {
|
||||
wsasock = curlx_sitosk(fd);
|
||||
wsaevents.lNetworkEvents = 0;
|
||||
|
|
@ -829,7 +829,7 @@ static int select_ws(int nfds, fd_set *readfds, fd_set *writefds,
|
|||
FD_CLR(wsasock, exceptfds);
|
||||
}
|
||||
else {
|
||||
/* try to handle the event with the WINSOCK2 functions */
|
||||
/* try to handle the event with the Winsock2 functions */
|
||||
wsaevents.lNetworkEvents = 0;
|
||||
error = WSAEnumNetworkEvents(wsasock, handle, &wsaevents);
|
||||
if(error != SOCKET_ERROR) {
|
||||
|
|
|
|||
|
|
@ -1117,7 +1117,7 @@ int main(int argc, char *argv[])
|
|||
|
||||
#ifdef USE_UNIX_SOCKETS
|
||||
if(socket_domain == AF_UNIX)
|
||||
logmsg("Listening on unix socket %s", unix_socket);
|
||||
logmsg("Listening on Unix socket %s", unix_socket);
|
||||
else
|
||||
#endif
|
||||
logmsg("Listening on port %hu", port);
|
||||
|
|
|
|||
|
|
@ -109,7 +109,7 @@ struct httprequest {
|
|||
bool auth; /* Authorization header present in the incoming request */
|
||||
size_t cl; /* Content-Length of the incoming request */
|
||||
bool digest; /* Authorization digest header found */
|
||||
bool ntlm; /* Authorization ntlm header found */
|
||||
bool ntlm; /* Authorization NTLM header found */
|
||||
int delay; /* if non-zero, delay this number of msec after connect */
|
||||
int writedelay; /* if non-zero, delay this number of milliseconds between
|
||||
writes in the response */
|
||||
|
|
|
|||
|
|
@ -28,7 +28,7 @@
|
|||
#include <netinet/in.h>
|
||||
#endif
|
||||
#ifdef _XOPEN_SOURCE_EXTENDED
|
||||
/* This define is "almost" required to build on HPUX 11 */
|
||||
/* This define is "almost" required to build on HP-UX 11 */
|
||||
#include <arpa/inet.h>
|
||||
#endif
|
||||
#ifdef HAVE_NETDB_H
|
||||
|
|
@ -143,7 +143,7 @@ static const char *win32_strerror(int err, char *buf, size_t buflen)
|
|||
return buf;
|
||||
}
|
||||
|
||||
/* use instead of perror() on generic windows */
|
||||
/* use instead of perror() on generic Windows */
|
||||
void win32_perror(const char *msg)
|
||||
{
|
||||
char buf[512];
|
||||
|
|
@ -166,7 +166,7 @@ void win32_init(void)
|
|||
|
||||
if(err) {
|
||||
perror("Winsock init failed");
|
||||
logmsg("Error initialising winsock -- aborting");
|
||||
logmsg("Error initialising Winsock -- aborting");
|
||||
exit(1);
|
||||
}
|
||||
|
||||
|
|
@ -190,7 +190,7 @@ void win32_cleanup(void)
|
|||
_flushall();
|
||||
}
|
||||
|
||||
/* socket-safe strerror (works on WinSock errors, too */
|
||||
/* socket-safe strerror (works on Winsock errors, too */
|
||||
const char *sstrerror(int err)
|
||||
{
|
||||
static char buf[512];
|
||||
|
|
@ -550,7 +550,7 @@ static void exit_signal_handler(int signum)
|
|||
* They are included for ANSI compatibility. Therefore, you can set
|
||||
* signal handlers for these signals by using signal, and you can also
|
||||
* explicitly generate these signals by calling raise. Source:
|
||||
* https://docs.microsoft.com/de-de/cpp/c-runtime-library/reference/signal
|
||||
* https://docs.microsoft.com/en-us/cpp/c-runtime-library/reference/signal
|
||||
*/
|
||||
static BOOL WINAPI ctrl_event_handler(DWORD dwCtrlType)
|
||||
{
|
||||
|
|
@ -690,7 +690,7 @@ static SIGHANDLER_T set_signal(int signum, SIGHANDLER_T handler,
|
|||
void install_signal_handlers(bool keep_sigalrm)
|
||||
{
|
||||
#ifdef _WIN32
|
||||
/* setup windows exit event before any signal can trigger */
|
||||
/* setup Windows exit event before any signal can trigger */
|
||||
exit_event = CreateEvent(NULL, TRUE, FALSE, NULL);
|
||||
if(!exit_event)
|
||||
logmsg("cannot create exit event");
|
||||
|
|
|
|||
|
|
@ -437,7 +437,7 @@ if((! -e pp($hstprvkeyf)) || (! -s pp($hstprvkeyf)) ||
|
|||
|
||||
|
||||
#***************************************************************************
|
||||
# Convert paths for curl's tests running on Windows with Cygwin/Msys OpenSSH
|
||||
# Convert paths for curl's tests running on Windows with Cygwin/MSYS OpenSSH
|
||||
#
|
||||
my $clipubkeyf_config;
|
||||
my $hstprvkeyf_config;
|
||||
|
|
|
|||
|
|
@ -150,7 +150,7 @@ $binext = '';
|
|||
$libext = '.la'; # .la since both libcurl and libcares are made with libtool
|
||||
if ($^O eq 'MSWin32' || $targetos) {
|
||||
if (!$targetos) {
|
||||
# If no target defined on Win32 lets assume vc
|
||||
# If no target defined on Windows, let's assume vc
|
||||
$targetos = 'vc';
|
||||
}
|
||||
if ($targetos =~ /vc/ || $targetos =~ /borland/) {
|
||||
|
|
@ -683,7 +683,7 @@ if (!$crosscompile || (($extvercmd ne '') && (-x $extvercmd))) {
|
|||
my $cmd = ($extvercmd ne '' ? $extvercmd.' ' : '')."./src/curl${binext} --version|";
|
||||
open($f, "<", $cmd);
|
||||
while(<$f>) {
|
||||
# strip CR from output on non-win32 platforms (wine on Linux)
|
||||
# strip CR from output on non-Windows platforms (WINE on Linux)
|
||||
s/\r// if ($^O ne 'MSWin32');
|
||||
print;
|
||||
}
|
||||
|
|
|
|||
|
|
@ -201,9 +201,9 @@ UNITTEST_START
|
|||
{ "COM56", 0,
|
||||
"COM56", SANITIZE_ERR_OK
|
||||
},
|
||||
/* At the moment we expect a maximum path length of 259. I assume MSDOS
|
||||
/* At the moment we expect a maximum path length of 259. I assume MS-DOS
|
||||
has variable max path lengths depending on compiler that are shorter
|
||||
so currently these "good" truncate tests won't run on MSDOS */
|
||||
so currently these "good" truncate tests will not run on MS-DOS */
|
||||
#ifndef MSDOS
|
||||
{ "AAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAAA"
|
||||
"BBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBBB"
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue