"Craig A. Berry" <[EMAIL PROTECTED]> writes:
> At 5:38 PM -0500 12/1/00, Charles Lane wrote:
> >I've been mucking about with this today, with mixed results.
> >
> >A little standalone program works fine, Perl from command line works fine.
> >
> >But it seems that that in the perl piped subprocesses we have
> >SYS$ERROR defined /EXEC by lib$spawn, defined /SUPER by the VMSPIPE
> >procedure when it redirects to inherit the parent's i/o, and defined
> >/USER inside Perl when we try to use option #3.
> >
> >My response is to change VMSPIPE to use a /USER definition of sys$error.
> >*That* now seems to work.
> I've tried the patch briefly and it does keep the error messages
> hidden when running filter-util.t outside of the test harness. I'm
> not sure the VMSPIPE part is going to work the way you intend though,
> because IIRC a user-mode logical only persists for the next image
> activation. The next command in vmspipe.com after setting the
> user-mode logical deletes a symbol and presumably uses up the
> user-mode logical before you get to the command for which you want it
> to be active.
I checked for this, and it seems that setting or deleting symbols are
operations that DCL does without activating an image.
> >I *suspect* the writing of messages to various mode logicals
> [snip]
> >Four error messages from a single error?
> This seems as likely as anything. Your internals book might clear
> this up. Another part might be that when you dup stderr the C RTL
> knows it's special and refuses to close it.
I looked, it didn't...at least I couldn't find anything about it.
What might be happening is that the exit handler goes through
USER, SUPER, EXEC mode logicals (in some order)...if SYS$OUTPUT
and SYS$ERROR point to the same thing (perhaps determined by
the 4-byte PPF RMS ID prefix?) then you get one message, otherwise
one to each. But I'm not sure if the comparison extends between
different mode logicals.
--
Drexel University \V --Chuck Lane
======]---------->--------*------------<-------[===========
(215) 895-1545 _/ \ Particle Physics
FAX: (215) 895-5934 /\ /~~~~~~~~~~~ [EMAIL PROTECTED]