line |
stmt |
bran |
cond |
sub |
pod |
time |
code |
1
|
|
|
|
|
|
|
package FusionInventory::Agent::Task::Inventory::Generic::Processes; |
2
|
|
|
|
|
|
|
|
3
|
1
|
|
|
1
|
|
97647353
|
use strict; |
|
1
|
|
|
|
|
13
|
|
|
1
|
|
|
|
|
79
|
|
4
|
1
|
|
|
1
|
|
10
|
use warnings; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
67
|
|
5
|
|
|
|
|
|
|
|
6
|
1
|
|
|
1
|
|
4
|
use English qw(-no_match_vars); |
|
1
|
|
|
|
|
33
|
|
|
1
|
|
|
|
|
21
|
|
7
|
|
|
|
|
|
|
|
8
|
1
|
|
|
1
|
|
1182
|
use FusionInventory::Agent::Tools; |
|
1
|
|
|
|
|
3
|
|
|
1
|
|
|
|
|
134
|
|
9
|
1
|
|
|
1
|
|
392
|
use FusionInventory::Agent::Tools::Unix; |
|
1
|
|
|
|
|
2
|
|
|
1
|
|
|
|
|
162
|
|
10
|
|
|
|
|
|
|
|
11
|
|
|
|
|
|
|
sub isEnabled { |
12
|
0
|
|
|
0
|
0
|
|
my (%params) = @_; |
13
|
|
|
|
|
|
|
|
14
|
|
|
|
|
|
|
return |
15
|
0
|
|
0
|
|
|
|
$OSNAME ne 'MSWin32' && |
16
|
|
|
|
|
|
|
!$params{no_category}->{process} && |
17
|
|
|
|
|
|
|
canRun('ps'); |
18
|
|
|
|
|
|
|
} |
19
|
|
|
|
|
|
|
|
20
|
|
|
|
|
|
|
sub doInventory { |
21
|
0
|
|
|
0
|
0
|
|
my (%params) = @_; |
22
|
|
|
|
|
|
|
|
23
|
0
|
|
|
|
|
|
my $inventory = $params{inventory}; |
24
|
0
|
|
|
|
|
|
my $logger = $params{logger}; |
25
|
|
|
|
|
|
|
|
26
|
0
|
|
|
|
|
|
foreach my $process (getProcesses(logger => $logger)) { |
27
|
0
|
|
|
|
|
|
$inventory->addEntry( |
28
|
|
|
|
|
|
|
section => 'PROCESSES', |
29
|
|
|
|
|
|
|
entry => $process |
30
|
|
|
|
|
|
|
); |
31
|
|
|
|
|
|
|
} |
32
|
|
|
|
|
|
|
} |
33
|
|
|
|
|
|
|
|
34
|
|
|
|
|
|
|
1; |