Beefy Boxes and Bandwidth Generously Provided by pair Networks
good chemistry is complicated,
and a little bit messy -LW
 
PerlMonks  

Re: Kill a process in perl windows and proceed only if it killed the process

by Anonymous Monk
on Jul 20, 2012 at 02:18 UTC ( #982742=note: print w/ replies, xml ) Need Help??


in reply to Kill a process in perl windows and proceed only if it killed the process

In the general case, killing a process is an asynchronous event ... it can take an arbitrary amount of time, especially if there are interactive dialog-boxes involved, and this can pragmatically result in situations like deadlock; or even actual deadlock of the user-interface. So, fire the bullet but don't wait for the body to hit the floor. Emphatically don't wait...


Comment on Re: Kill a process in perl windows and proceed only if it killed the process
Re^2: Kill a process in perl windows and proceed only if it killed the process
by prashantktyagi (Scribe) on Jul 20, 2012 at 10:18 UTC

    will system(kill -9 <pid>) not work here ? I am just curious...

      Not on Windows. And if you are on a POSIX system, why shell out instead of using the built-in kill?
      Indeed, on Linux I myself prefer system(shutdown -r now).
      --
      if ( 1 ) { $postman->ring() for (1..2); }

Log In?
Username:
Password:

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

How do I use this? | Other CB clients
Other Users?
Others exploiting the Monastery: (7)
As of 2015-07-04 11:15 GMT
Sections?
Information?
Find Nodes?
Leftovers?
    Voting Booth?

    The top three priorities of my open tasks are (in descending order of likelihood to be worked on) ...









    Results (59 votes), past polls