fix: Fix can't find CPQHOST-MIB (#8024)

This commit is contained in:
Tony Murray
2018-01-04 16:42:16 -06:00
committed by Neil Lathwood
parent 91cd338c35
commit 4ffdbe0e6a
2 changed files with 4 additions and 3 deletions

View File

@@ -583,11 +583,12 @@ function snmpwalk_cache_triple_oid($device, $oid, $array, $mib = null, $mibdir =
* @param string $mib The MIB to use
* @param int $depth how many indexes to group
* @param array $array optionally insert the entries into an existing array (helpful for grouping multiple walks)
* @param string $mibdir custom mib dir to search for mib
* @return array grouped array of data
*/
function snmpwalk_group($device, $oid, $mib = '', $depth = 1, $array = array())
function snmpwalk_group($device, $oid, $mib = '', $depth = 1, $array = array(), $mibdir = null)
{
$cmd = gen_snmpwalk_cmd($device, $oid, '-OQUsetX', $mib);
$cmd = gen_snmpwalk_cmd($device, $oid, '-OQUsetX', $mib, $mibdir);
$data = rtrim(external_exec($cmd));
$line = strtok($data, "\n");