]> git.ipfire.org Git - thirdparty/curl.git/commitdiff
sshserver.pl: use cached Win32 environment check variable
authorMarc Hoersken <info@marc-hoersken.de>
Sun, 5 Apr 2020 16:46:42 +0000 (18:46 +0200)
committerMarc Hoersken <info@marc-hoersken.de>
Fri, 10 Apr 2020 19:03:24 +0000 (21:03 +0200)
tests/sshserver.pl

index 59ea0ae1e82a42c06abbd73289cc6e99167002c3..084b4a83c6dd7abec685d965ba64d9d67722102b 100644 (file)
@@ -405,7 +405,7 @@ my $hstprvkeyf_config = abs_path("$path/$hstprvkeyf");
 my $pidfile_config = $pidfile;
 my $sftpsrv_config = $sftpsrv;
 
-if ($^O eq 'MSWin32' || $^O eq 'cygwin' || $^O eq 'msys') {
+if (pathhelp::os_is_win()) {
     # Ensure to use MinGW/Cygwin paths
     $clipubkeyf_config = pathhelp::build_sys_abs_path($clipubkeyf_config);
     $hstprvkeyf_config = pathhelp::build_sys_abs_path($hstprvkeyf_config);
@@ -797,7 +797,7 @@ if((! -e $knownhosts) || (! -s $knownhosts)) {
 my $identity_config = abs_path("$path/$identity");
 my $knownhosts_config = abs_path("$path/$knownhosts");
 
-if ($^O eq 'MSWin32' || $^O eq 'cygwin' || $^O eq 'msys') {
+if (pathhelp::os_is_win()) {
     # Ensure to use MinGW/Cygwin paths
     $identity_config = pathhelp::build_sys_abs_path($identity_config);
     $knownhosts_config = pathhelp::build_sys_abs_path($knownhosts_config);