From: Amos Jeffries Date: Thu, 19 Mar 2009 13:52:49 +0000 (+1300) Subject: Coverity detected buffer access error X-Git-Tag: SQUID_3_2_0_1~1113 X-Git-Url: http://git.ipfire.org/?a=commitdiff_plain;h=c3ae32cc658cad350764d264acc176e6d08eb51d;p=thirdparty%2Fsquid.git Coverity detected buffer access error Defined values for SNMP error use decimal values 0-9, 17-24 not 0-19. Thus the static list of message mappings is out by 6. --- diff --git a/snmplib/snmp_error.c b/snmplib/snmp_error.c index 3fc747fce3..d2edea084b 100644 --- a/snmplib/snmp_error.c +++ b/snmplib/snmp_error.c @@ -46,6 +46,14 @@ static const char *error_string[19] = { "WRONGTYPE", "WRONGLENGTH", "WRONGENCODING", + +/* 0xA */"UNDEFINED", +/* 0xb */"UNDEFINED", +/* 0xC */"UNDEFINED", +/* 0xD */"UNDEFINED", +/* 0xE */"UNDEFINED", +/* 0xF */"UNDEFINED", + "WRONGVALUE", "NOCREATION", "INCONSISTENTVALUE",