|
From: <son...@us...> - 2008-04-24 17:18:48
|
Revision: 303
http://cbench.svn.sourceforge.net/cbench/?rev=303&view=rev
Author: sonicsoft70
Date: 2008-04-24 10:18:28 -0700 (Thu, 24 Apr 2008)
Log Message:
-----------
tweaks and such
Modified Paths:
--------------
trunk/cbench/tools/kill_stuff
Modified: trunk/cbench/tools/kill_stuff
===================================================================
--- trunk/cbench/tools/kill_stuff 2008-04-23 22:44:45 UTC (rev 302)
+++ trunk/cbench/tools/kill_stuff 2008-04-24 17:18:28 UTC (rev 303)
@@ -3,6 +3,8 @@
use Getopt::Long;
GetOptions(
'match=s' => \$match,
+ 'force' => \$force,
+ 'debug' => \$DEBUG,
);
if (! defined $match) {
@@ -13,7 +15,11 @@
@ps = `ps wax`;
foreach (@ps) {
- /kill_stuff|ntpd|portmap|rpc.statd|udevd|mingetty|pbs_mom|sshd|\[.*\]/ and next;
+ /kill_stuff/ and next;
+ (defined $DEBUG) and (/$match/ and print "DEBUG=> $_");
+ (!defined $force) and (/kill_stuff|ntpd|portmap|rpc.statd|udevd|mingetty|pbs_mom|sshd|^\[.*\]/ and next);
+ (defined $force) and (/kill_stuff|ntpd|portmap|rpc.statd|udevd|mingetty|sshd|^\[.*\]/ and next);
+ #print $_;
next unless /$match/;
#print "$_";
($pid, $state, $name) = /^\s*(\d+)\s+\S+\s+(\S+)\s+\S+\s+(.*)$/;
This was sent by the SourceForge.net collaborative development platform, the world's largest Open Source development site.
|