]> CyberLeo.Net >> Repos - FreeBSD/stable/10.git/commit
MFC r310931,r310942,r310988:
authorngie <ngie@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Sat, 7 Jan 2017 08:44:15 +0000 (08:44 +0000)
committerngie <ngie@ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f>
Sat, 7 Jan 2017 08:44:15 +0000 (08:44 +0000)
commit97eabf56c0b133550efc5ef84d1fc6e978890a11
tree0a9bd7f649c8698c6432f7c0825e936cec37d2cb
parentbea788a31f8a11026e3a8256267a2f9574487c16
MFC r310931,r310942,r310988:

r310931:

Use strdup in snmp_parse_server(..) when possible instead of malloc+strcpy

This simplifies the code and mutes a Coverity warning about sc->cport being
improperly allocated

CID: 1018247

r310942:

Unbreak the build by passing the string to strdup, not its length

Pointyhat to: ngie

r310988:

snmp_discover_engine: fix up req/resp (PDU object) handling a bit

- Call snmp_pdu_free on req and resp when done with the objects
- Call snmp_pdu_free on req before calling snmp_pdu_create on it
  again

git-svn-id: svn://svn.freebsd.org/base/stable/10@311593 ccf9f872-aa2e-dd11-9fc8-001c23d0bc1f
contrib/bsnmp/lib/snmpclient.c