From ee4ae0b2af4e4877bceeb0aebcd691a12e5898ff Mon Sep 17 00:00:00 2001 From: Tony Murray Date: Tue, 19 May 2020 08:22:57 -0500 Subject: [PATCH] Fix inconsistent escapes (#11637) should probably stripslashes() instead --- includes/snmp.inc.php | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/includes/snmp.inc.php b/includes/snmp.inc.php index 92a3cfc0b1..e4f469a8ea 100644 --- a/includes/snmp.inc.php +++ b/includes/snmp.inc.php @@ -274,7 +274,7 @@ function snmp_get($device, $oid, $options = null, $mib = null, $mibdir = null) } $cmd = gen_snmpget_cmd($device, $oid, $options, $mib, $mibdir); - $data = trim(external_exec($cmd), "\" \n\r"); + $data = trim(external_exec($cmd), "\\\" \n\r"); recordSnmpStatistic('snmpget', $time_start); if (preg_match('/(No Such Instance|No Such Object|No more variables left|Authentication failure)/i', $data)) {