From: Vojtech Vilimek Date: Wed, 30 Aug 2023 15:22:52 +0000 (+0200) Subject: Minor bugfix X-Git-Url: http://git.ipfire.org/cgi-bin/gitweb.cgi?a=commitdiff_plain;h=3c718d162cad94f23fb360f7ffda6b8985f80fef;p=thirdparty%2Fbird.git Minor bugfix --- diff --git a/proto/snmp/subagent.c b/proto/snmp/subagent.c index f0d85f8d2..2a08a70dc 100644 --- a/proto/snmp/subagent.c +++ b/proto/snmp/subagent.c @@ -615,10 +615,10 @@ do_response(struct snmp_proto *p, byte *buf, uint size UNUSED) u8 snmp_get_mib_class(const struct oid *oid) { - ASSUME(oid->n_subid > 2); if (oid->prefix != 2 && oid->ids[0] != SNMP_MIB_2) return SNMP_CLASS_INVALID; + ASSUME(oid->n_subid > 1); switch (oid->ids[1]) { case SNMP_BGP4_MIB: