Beefy Boxes and Bandwidth Generously Provided by pair Networks
XP is just a number
 
PerlMonks  

Re^2: Child process lingers after keyboard interrupt on Windows

by toughy (Acolyte)
on Oct 20, 2018 at 10:55 UTC ( [id://1224381]=note: print w/replies, xml ) Need Help??


in reply to Re: Child process lingers after keyboard interrupt on Windows
in thread Child process lingers after keyboard interrupt on Windows

Thank you for the hint on this module.

I believe Proc::Simple does not yet work on Windows. With Strawberry perl, installation from CPAN hangs during 'Building and testing Proc-Simple-1.32', and with ActivePerl from ActiveState the .ppm build failed on all Windows versions: http://code.activestate.com/ppm/Proc-Simple/

I looked at the source on CPAN and what it does is fork() and exec(). I never tried it until now because I found it unintuitive that fork() will work properly on Windows, while IPC::Run will not, but I will try it. I do not like how Proc::Simple will exit(0); after exec() fails, I think that is a silent error and it can be dangerous.

--
Thank you,
Timothy Madden

  • Comment on Re^2: Child process lingers after keyboard interrupt on Windows

Replies are listed 'Best First'.
Re^3: Child process lingers after keyboard interrupt on Windows
by toughy (Acolyte) on Oct 23, 2018 at 19:45 UTC

    So trying to fork() I run into the this issue:

    When the pseudo-child process (really a new thread in the parent, see perl fork() emulation for Windows) reopens STDOUT, the parent STDOUT changes as well. Although perl documentation says the open handles are duplicated on emulated fork(), to prevent this issue.

Log In?
Username:
Password:

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

How do I use this?Last hourOther CB clients
Other Users?
Others browsing the Monastery: (3)
As of 2024-04-16 03:49 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    No recent polls found