ant-user mailing list archives

Site index · List index
Message view « Date » · « Thread »
Top « Date » · « Thread »
From "Nir Geier" <Nir.Ge...@unipier.com>
Subject Ninju: How to stop process using exec?
Date Mon, 30 May 2005 08:39:11 GMT
TY, Ninju

I understood from u that mu assumption was correct.
There isnt any way to kill process under windows.

ty.


-----Original Message-----
From: Ninju Bohra [mailto:ninju_bohra@yahoo.com]
Sent: Monday, May 30, 2005 5:46 AM
To: Ant Users List
Subject: Re: How to stop process using exec?


Windows does not come with a "kill" utility by
default.  There is a "kill" utility in the NT resource
kit (which useable on OSes above NT).  There is also a
enhanced PSKill utility from SysInternals
(http://www.sysinternals.com) which you can use.

The hardest part of killing a process (regardless of
the OS) is determining someway to indentify the proces
to the "kill" program.  The PID (process ID) is
usually the most exact way, however it difficult to
obtain the PID externally.  Some "kill" program
(PSKill for example) can also take the process name.

I would highly recommend NOT using the OS to kill a
process.  OS killing of process is a very messy deal
(particulary on Windows) which can result in resource
leakage, Protection faults and Process Termination
Dialog boxes appearing.  It is advisable to seek
another way to accomplish your goal.

Later,

Ninju

--- Nir Geier <Nir.Geier@unipier.com> wrote:

> hi all,
> 
> Does anyone knows how can I stop process under
> windows?
> 
> For example: 
> executing the following (Under Windows):
> 
> <target name="name" description="desc">
> 	<exec executable="cmd.exe">
> 		<arg line="/c ping -t 127.0.0.1"/>
> 	</exec>
> </target>
> 
> is there any way to write ant to stop the target?
> 
> Nir Geier.
> 
>
---------------------------------------------------------------------
> To unsubscribe, e-mail:
> user-unsubscribe@ant.apache.org
> For additional commands, e-mail:
> user-help@ant.apache.org
> 
> 



		
__________________________________ 
Yahoo! Mail 
Stay connected, organized, and protected. Take the tour: 
http://tour.mail.yahoo.com/mailtour.html 


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


---------------------------------------------------------------------
To unsubscribe, e-mail: user-unsubscribe@ant.apache.org
For additional commands, e-mail: user-help@ant.apache.org


Mime
View raw message