Page MenuHomeFreeBSD

sbin/dhclient: fix `vendor` storage leak in parse_option_decl(..)
ClosedPublic

Authored by ngie on Mar 13 2017, 5:19 PM.
Tags
None
Referenced Files
Unknown Object (File)
Thu, Sep 24, 11:46 PM
Unknown Object (File)
Thu, Sep 24, 6:08 PM
Unknown Object (File)
Thu, Sep 24, 5:50 PM
Unknown Object (File)
Thu, Sep 24, 5:50 PM
Unknown Object (File)
Thu, Sep 24, 4:41 PM
Unknown Object (File)
Tue, Sep 22, 9:39 PM
Unknown Object (File)
Sat, Sep 19, 10:05 AM
Unknown Object (File)
Sat, Sep 19, 1:55 AM
Subscribers

Details

Summary

sbin/dhclient: fix vendor storage leak in parse_option_decl(..)

This ensures the storage isn't leaked when non-NULL and the function
returns early, prior to the free(vendor) later on in the function.

MFC after: 1 week
Reported by: Coverity
CID: 1007111-1007113
Sponsored by: Dell EMC Isilon

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Not Applicable
Unit
Tests Not Applicable

Event Timeline

Remove goto label; free when exiting function, prior to free(vendor) on line 757 (missed
when reviewing the code previously).

This revision is now accepted and ready to land.Mar 13 2017, 5:37 PM