mirror of
https://github.com/opnsense/src.git
synced 2026-06-11 09:41:03 -04:00
Don't try to free string (stack allocated char[])
Fix minor style with warnx call while in the neighborhood MFC after: 1 week CID: 1009683 Reported by: Coverity, gcc 5.x Sponsored by: EMC / Isilon Storage Division
This commit is contained in:
parent
81b3868083
commit
9899399c06
1 changed files with 1 additions and 2 deletions
|
|
@ -1079,10 +1079,9 @@ snmp_oid2asn_oid(struct snmp_toolinfo *snmptoolctx, char *str,
|
|||
strlcpy(string, str, i + 1);
|
||||
string[i] = '\0';
|
||||
if (snmp_lookup_enumoid(snmptoolctx, &obj, string) < 0) {
|
||||
warnx("Unknown string - %s",string);
|
||||
warnx("Unknown string - %s", string);
|
||||
return (NULL);
|
||||
}
|
||||
free(string);
|
||||
}
|
||||
|
||||
asn_append_oid(oid, &(obj.val.var));
|
||||
|
|
|
|||
Loading…
Reference in a new issue