in reply to Re: Quote marks lost in system() calls
in thread Quote marks lost in system() calls
if ( @ARGV ) {
foreach my $i ( 0 .. $#ARGV ) {
print "ARVG[$i]: ", $ARGV[$i], "\n";
}
exit(0);
}
system("perl $0 foo bar");
system('perl ' . $0 . ' "foo bar"');
system("perl $0 foo \"bar baz\"");
system("perl $0 foo \"\"bar baz\"\"");
system("perl", $0, "foo", '"bar baz"');
which yielded
ARVG[0]: foo ARVG[1]: bar ARVG[0]: foo bar ARVG[0]: foo ARVG[1]: bar baz ARVG[0]: foo ARVG[1]: bar ARVG[2]: baz ARVG[0]: foo ARVG[1]: bar bazUnless I missed something, this suggests that you may be SOL on getting the doublequotes passed through on NT.
|
|---|
| Replies are listed 'Best First'. | |
|---|---|
|
Re: Re: Re: Quote marks lost in system() calls
by runrig (Abbot) on Dec 21, 2000 at 05:51 UTC | |
by dws (Chancellor) on Dec 21, 2000 at 22:37 UTC |