add EUID set search
This commit is contained in:
parent
e16b93a1bc
commit
155bedbdce
|
@ -19,8 +19,8 @@ sub help{
|
||||||
|
|
||||||
--cF Show children major faults.
|
--cF Show children major faults.
|
||||||
|
|
||||||
-m <pctmem> Memory usage percent to search for.
|
--eu Search for proccs witha EUID set.
|
||||||
--mi Invert the memory usage search.
|
--eui Invert the EUID search.
|
||||||
|
|
||||||
-f Show minor faults.
|
-f Show minor faults.
|
||||||
|
|
||||||
|
@ -30,6 +30,9 @@ sub help{
|
||||||
-j <jids> A comma seperated list of JIDs to search for.
|
-j <jids> A comma seperated list of JIDs to search for.
|
||||||
--ji Invert the JIDs earch.
|
--ji Invert the JIDs earch.
|
||||||
|
|
||||||
|
-m <pctmem> Memory usage percent to search for.
|
||||||
|
--mi Invert the memory usage search.
|
||||||
|
|
||||||
-n Show number of threads.
|
-n Show number of threads.
|
||||||
|
|
||||||
--nc disable color.
|
--nc disable color.
|
||||||
|
@ -99,6 +102,7 @@ my $jids_string;
|
||||||
my $jids_invert=0;
|
my $jids_invert=0;
|
||||||
my $uids_string;
|
my $uids_string;
|
||||||
my $uids_invert=0;
|
my $uids_invert=0;
|
||||||
|
my $euid=0;
|
||||||
|
|
||||||
# get the commandline options
|
# get the commandline options
|
||||||
Getopt::Long::Configure ('no_ignore_case');
|
Getopt::Long::Configure ('no_ignore_case');
|
||||||
|
@ -139,6 +143,7 @@ GetOptions(
|
||||||
'ji' => \$jids_invert,
|
'ji' => \$jids_invert,
|
||||||
'u=s' => \$uids_string,
|
'u=s' => \$uids_string,
|
||||||
'ui' => \$uids_invert,
|
'ui' => \$uids_invert,
|
||||||
|
'eu' => \$euid,
|
||||||
);
|
);
|
||||||
|
|
||||||
# print the version info if requested
|
# print the version info if requested
|
||||||
|
@ -292,6 +297,18 @@ if ( defined( $uids_string ) ){
|
||||||
});
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
|
#
|
||||||
|
# handles the EUID set search
|
||||||
|
#
|
||||||
|
if ( $euid ){
|
||||||
|
push( @filters, {
|
||||||
|
type=>'EUIDset',
|
||||||
|
invert=>$uids_invert,
|
||||||
|
args=>{
|
||||||
|
},
|
||||||
|
});
|
||||||
|
}
|
||||||
|
|
||||||
# XOR common boolean CLI flags
|
# XOR common boolean CLI flags
|
||||||
if ( defined( $ENV{NCPS_jid} ) ){
|
if ( defined( $ENV{NCPS_jid} ) ){
|
||||||
$jid = $jid ^ 1;
|
$jid = $jid ^ 1;
|
||||||
|
|
Loading…
Reference in New Issue