diff --git a/centreon-plugins/src/check_centreon_snmp_traffic b/centreon-plugins/src/check_centreon_snmp_traffic index 4cdb7c87f..6ef65be44 100644 --- a/centreon-plugins/src/check_centreon_snmp_traffic +++ b/centreon-plugins/src/check_centreon_snmp_traffic @@ -254,6 +254,11 @@ if ($mustCreateFile) { print FILE $interfaceIndex.";".$result->{$key}."\n"; } close(FILE); + } else { + if (!$result) { + printf("ERROR: Cannot get SNMP info : %s", $session->error); + exit $ERRORS{'UNKNOWN'}; + } } }