From 3e4ab3d764d6f321e2f9d23967fd2731eebf1331 Mon Sep 17 00:00:00 2001 From: bayashi Date: Sun, 4 Aug 2019 02:49:17 +0900 Subject: [PATCH] Change function for Win32 --- lib/ShellQuote/Any.pm | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/lib/ShellQuote/Any.pm b/lib/ShellQuote/Any.pm index 4b7bc42..bd6d6a1 100644 --- a/lib/ShellQuote/Any.pm +++ b/lib/ShellQuote/Any.pm @@ -53,7 +53,7 @@ sub _require { sub _win32_quote { my ($cmd) = @_; - Win32::ShellQuote::cmd_escape(join ' ', @$cmd); + Win32::ShellQuote::quote_system_string(join ' ', @$cmd); } sub _bourne_quote { @@ -97,6 +97,8 @@ ShellQuote::Any escapes strings for the shell on Linux, UNIX or MSWin32. If this method was called without C<$os>, then C<\@cmd> escapes for current OS. C<$os> supports C or C. +NOTE that if you would execute a result of C, it should be without redirection, especially Win32. + =head1 REPOSITORY