Beefy Boxes and Bandwidth Generously Provided by pair Networks
Your skill will accomplish
what the force of many cannot
 
PerlMonks  

Re: Detect whether a writeable filehandle has closed?

by talexb (Chancellor)
on Jan 13, 2021 at 17:33 UTC ( [id://11126854]=note: print w/replies, xml ) Need Help??


in reply to Detect whether a writeable filehandle has closed?

Maybe an END block in the child could signal that the filehandle is gone?

Another approach would involve subclassing the filehandle .. ugh.

Alex / talexb / Toronto

Thanks PJ. We owe you so much. Groklaw -- RIP -- 2003 to 2013.

Replies are listed 'Best First'.
Re^2: Detect whether a writeable filehandle has closed?
by jdporter (Paladin) on Jan 13, 2021 at 17:57 UTC
    Maybe an END block in the child could signal that the filehandle is gone

    The child is not perl, it's a compiled C program.

      OK, so perhaps using the _atexit call (or whatever the equivalent is in your RTL) in the C code. The general idea is for the code to catch that the child has exitted and signal the caller.

      Alex / talexb / Toronto

      Thanks PJ. We owe you so much. Groklaw -- RIP -- 2003 to 2013.

Log In?
Username:
Password:

What's my password?
Create A New User
Domain Nodelet?
Node Status?
node history
Node Type: note [id://11126854]
help
Chatterbox?
and the web crawler heard nothing...

How do I use this?Last hourOther CB clients
Other Users?
Others learning in the Monastery: (5)
As of 2024-03-28 21:01 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found