[Israel.pm] using "system"

Shlomi Fish shlomif at iglu.org.il
Sun Oct 31 05:22:23 PST 2004

On Sunday 31 October 2004 14:23, Offer Kaye wrote:
> On Sun, 31 Oct 2004 11:28:30 +0000, Mikhael Goikhman <migo at homemail.com> 
> > Here is an example of both:
> >
> >   system("ls", "-al");
> >
> >   system {"ls"} "dir", "-al";
> I think I get it - the "system PROGRAM LIST" format of the command is
> just a way of "fooling" the program into thinking it is running as
> "dir" while it is really running "ls"?
> What is that good for?

Like for example, using the gzip executable to uncompress a file by setting 
its argv[0] to "gunzip".


	Shlomi Fish

Shlomi Fish      shlomif at iglu.org.il
Homepage:        http://www.shlomifish.org/

Knuth is not God! It took him two days to build the Roman Empire.

More information about the Perl mailing list