Skip to content

Commit

Permalink
Fix fping command to not output stderr (#8)
Browse files Browse the repository at this point in the history
  • Loading branch information
Hipska authored Apr 3, 2024
1 parent 58c3422 commit 546cdc1
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion src/TeemIpDiscoveryIPv4Collector.class.inc.php
Original file line number Diff line number Diff line change
Expand Up @@ -230,7 +230,7 @@ protected function PingIpv4Ips($sTimeStamp)
Utils::Log(LOG_INFO, "Start to ping subnet: ".$sSubnetIp);

// fping if available
if (isset($sFpingCmd)) exec(sprintf('%s -r1 -t%d -ga %s %s', $sFpingCmd, $iTimeOut*1000, long2ip($iIp), long2ip($iBroadcastIp-1)), $aFPingResults);
if (isset($sFpingCmd)) exec(sprintf('%s -r1 -t%d -ga %s %s 2>&1', $sFpingCmd, $iTimeOut*1000, long2ip($iIp), long2ip($iBroadcastIp-1)), $aFPingResults);

while ($iIp < $iBroadcastIp) {
$sIp = long2ip($iIp);
Expand Down

0 comments on commit 546cdc1

Please sign in to comment.