fix use for on FreeBSD
This commit is contained in:
parent
529fe02f05
commit
ae3b04a789
|
@ -1,5 +1,8 @@
|
||||||
Revision history for Net-Connection-ncnetstat
|
Revision history for Net-Connection-ncnetstat
|
||||||
|
|
||||||
|
0.6.3 2021-02-16/10:30
|
||||||
|
- Fix at runtime module use to actually work now. Thanks Grinnz, Botje!
|
||||||
|
|
||||||
0.6.2 2021-02-16/02:30
|
0.6.2 2021-02-16/02:30
|
||||||
- Remove it accidentally using Net::Conection::lsof always.
|
- Remove it accidentally using Net::Conection::lsof always.
|
||||||
|
|
||||||
|
|
|
@ -11,12 +11,9 @@ use Proc::ProcessTable;
|
||||||
use Text::ANSITable;
|
use Text::ANSITable;
|
||||||
|
|
||||||
# use Net::Connection::FreeBSD_sockstat if possible
|
# use Net::Connection::FreeBSD_sockstat if possible
|
||||||
if ( $^O =~ /freebsd/ ) {
|
use if $^O =~ /freebsd/, 'Net::Connection::FreeBSD_sockstat';
|
||||||
use Net::Connection::FreeBSD_sockstat;
|
use if $^O !~ /freebsd/, 'Net::Connection::lsof';
|
||||||
}
|
|
||||||
else {
|
|
||||||
use Net::Connection::lsof;
|
|
||||||
}
|
|
||||||
|
|
||||||
=head1 NAME
|
=head1 NAME
|
||||||
|
|
||||||
|
@ -180,7 +177,7 @@ sub run {
|
||||||
@objects = &lsof_to_nc_objects;
|
@objects = &lsof_to_nc_objects;
|
||||||
}
|
}
|
||||||
else {
|
else {
|
||||||
@objects = &sockstat_to_nc_objects;
|
@objects = sockstat_to_nc_objects;
|
||||||
}
|
}
|
||||||
|
|
||||||
my @found;
|
my @found;
|
||||||
|
|
Loading…
Reference in New Issue