in reply to Error using back tick operators if it has special perl chars in it

To expand a bit on japhy's response, you will be best served by using a piping form of open, with the parameters in list form. Using list form will prevent any shell expansion on the parameters, which avoids many problems. Here's a very simple example:

open my $lsfh, "-|", "ls", "-l" or die "Cannot open pipe from 'ls': $!"; while (<$lsfh>) { print; } close $lsfh;
  • Comment on Re: Error using back tick operators if it has special perl chars in it
  • Download Code