Small speed optimization. Check parent_detection from the outer loop.
This commit is contained in:
parent
895ec34a4f
commit
e5d29d4c3b
|
@ -1154,7 +1154,7 @@ sub scan($) {
|
|||
|
||||
# Get a list of found hosts.
|
||||
my @hosts = @{$self->get_hosts()};
|
||||
if (scalar(@hosts) > 0) {
|
||||
if (scalar(@hosts) > 0 && $self->{'parent_detection'} == 1) {
|
||||
# Delete previous connections.
|
||||
$self->call('delete_connections');
|
||||
|
||||
|
|
Loading…
Reference in New Issue