Path: utzoo!attcan!uunet!jarthur!ucivax!orion.oac.uci.edu!ucsd!ucbvax!hplabs!hpcc05!hpcc01!okamoto From: okamoto@hpcc01.HP.COM (Jeff Okamoto) Newsgroups: comp.lang.perl Subject: Re: Starting editor from within perl script Message-ID: <1180001@hpcc01.HP.COM> Date: 26 Sep 90 22:29:31 GMT References: <1990Sep21.190641.9221@cs.rochester.edu> Organization: HP Corp Computing & Services Lines: 36 allbery@NCoast.ORG (Brandon S. Allbery KB8JRR/KT) writes: > The whole point of `` is that, as in a shell, the standard output and > standard error of the program are trapped and returned to Perl as a > (very large...) string (or list, depending on context). This is not the behavior I see on an HP 9000/800 running HP-UX A.B7.00. If I say: @test = `./a.out`; print "Out: @test"; where a.out is the simple C program: main() { printf("Hello, "); fprintf(stderr, "world.\n"); } I get: % perl backticktest world. Out: Hello, Because of this, I've written a subroutine to capture both the standard output and error and return it in a list. -- ___________ The New Number Who, / ____ / / Jeff Okamoto /_/ / / / HP Corporate Computing & Services / / / GUNDAM okamoto@ranma.corp.hp.com / / / __ / / /___/ / (415) 857-6236 / /__________/ "Zeta Gundam, Camille, ikimasu!"