Path: utzoo!utgpu!jarvis.csri.toronto.edu!cs.utexas.edu!usc!elroy.jpl.nasa.gov!jpl-devvax!lwall From: lwall@jpl-devvax.JPL.NASA.GOV (Larry Wall) Newsgroups: comp.lang.perl Subject: Re: STDOUT & STDERR from a dumped perl script Message-ID: <7331@jpl-devvax.JPL.NASA.GOV> Date: 8 Mar 90 00:00:09 GMT References: <1648@sparko.gwu.edu> <7274@jpl-devvax.JPL.NASA.GOV> <2600@ruuinf.cs.ruu.nl> Reply-To: lwall@jpl-devvax.JPL.NASA.GOV (Larry Wall) Organization: Jet Propulsion Laboratory, Pasadena, CA Lines: 22 In article <2600@ruuinf.cs.ruu.nl> piet@cs.ruu.nl (Piet van Oostrum) writes: : Larry, we had that problem in one of the earliest versions of perl3.0. : I had a patch then, but that got lost. The problem is in the abort() call. : It closes the files, and that means on most systems, clearing the flags. So : you must abstain from closing, i.e you must have some alternative to abort : that doesn't close the files. (Like just sending a signal to yourself). You : should flush the files however. (There is no portable way to flush all open : files, unless you keep a list of the open files yourself.) I tried doing a kill(getpid(),SIGIOT), but that seems to have the same effect as abort() in terms of wiping out _flag. We don't have to worry about files other than std*, since we can't keep them open anyway. An fflush(stdout) is about all that's needed. But the kill didn't work. Is some library routine catching the signal somehow? No, signal(SIGIOT,SIG_DFL) doesn't change things. How do they close it? Does the kernel do it? I still suspect the startup code. Larry