[Idle-dev] Terminating subprocesses

Chui Tey teyc@cognoware.com
Tue, 25 Feb 2003 08:45:59 +1000


This is a multi-part message in MIME format.

------=_NextPart_000_0010_01C2DCAA.530BABA0
Content-Type: text/plain;
	charset="iso-8859-1"
Content-Transfer-Encoding: 7bit

Kurt,

In the case of windows, we could kill a subprocess using the

self.rpcpid = os.spawnv(os.P_NOWAIT, args[0], args)
.
.
.
import win32process
win32process.TerminateProcess(self.rpcpid,0)


Chui
 

------=_NextPart_000_0010_01C2DCAA.530BABA0
Content-Type: text/html;
	charset="iso-8859-1"
Content-Transfer-Encoding: quoted-printable

<!DOCTYPE HTML PUBLIC "-//W3C//DTD HTML 3.2//EN">
<HTML>
<HEAD>
<META HTTP-EQUIV=3D"Content-Type" CONTENT=3D"text/html; =
charset=3DWindows-1252">
<META NAME=3D"Generator" CONTENT=3D"MS Exchange Server version =
6.0.5762.3">
<TITLE>Terminating subprocesses</TITLE>
</HEAD>
<BODY>
<!-- Converted from text/plain format -->

<P><FONT SIZE=3D2>Kurt,</FONT>
</P>

<P><FONT SIZE=3D2>In the case of windows, we could kill a subprocess =
using the</FONT>
</P>

<P><FONT SIZE=3D2>self.rpcpid =3D os.spawnv(os.P_NOWAIT, args[0], =
args)</FONT>

<BR><FONT SIZE=3D2>.</FONT>

<BR><FONT SIZE=3D2>.</FONT>

<BR><FONT SIZE=3D2>.</FONT>

<BR><FONT SIZE=3D2>import win32process</FONT>

<BR><FONT SIZE=3D2>win32process.TerminateProcess(self.rpcpid,0)</FONT>
</P>
<BR>

<P><FONT SIZE=3D2>Chui</FONT>

<BR><FONT SIZE=3D2>&nbsp;</FONT>
</P>

</BODY>
</HTML>
------=_NextPart_000_0010_01C2DCAA.530BABA0--