svn commit: r298462 - head/contrib/bsnmp/snmp_mibII
Garrett Cooper
ngie at FreeBSD.org
Fri Apr 22 07:51:39 UTC 2016
Author: ngie
Date: Fri Apr 22 07:51:38 2016
New Revision: 298462
URL: https://svnweb.freebsd.org/changeset/base/298462
Log:
Return `ret` in op_ifentry(..) to mute a -Wunused-but-set-variable warning
This will also now detect error conditions with
value->var.subs[sub - 1] == LEAF_ifPhysAddress where `string_get(..)`
could fail if iifp->physaddr and/or iifp->physaddrlen were deemed
invalid.
MFC after: 2 weeks
CID: 1006551
Reported by: Coverity, gcc
Sponsored by: EMC / Isilon Storage Division
Modified:
head/contrib/bsnmp/snmp_mibII/mibII_interfaces.c
Directory Properties:
head/ (props changed)
Modified: head/contrib/bsnmp/snmp_mibII/mibII_interfaces.c
==============================================================================
--- head/contrib/bsnmp/snmp_mibII/mibII_interfaces.c Fri Apr 22 07:29:38 2016 (r298461)
+++ head/contrib/bsnmp/snmp_mibII/mibII_interfaces.c Fri Apr 22 07:51:38 2016 (r298462)
@@ -356,7 +356,7 @@ op_ifentry(struct snmp_context *ctx, str
value->v.oid = ifp->spec_oid;
break;
}
- return (SNMP_ERR_NOERROR);
+ return (ret);
}
/*
More information about the svn-src-head
mailing list