Page MenuHomeFreeBSD

Fix a regression in r310638.
ClosedPublic

Authored by kib on Jan 4 2017, 10:39 AM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, Apr 15, 6:16 AM
Unknown Object (File)
Wed, Apr 2, 10:45 PM
Unknown Object (File)
Mar 16 2025, 3:39 AM
Unknown Object (File)
Feb 13 2025, 6:11 PM
Unknown Object (File)
Feb 12 2025, 6:51 AM
Unknown Object (File)
Feb 7 2025, 5:48 PM
Unknown Object (File)
Feb 7 2025, 4:01 PM
Unknown Object (File)
Feb 4 2025, 7:54 PM
Subscribers

Details

Summary

The callers of kern_getfsstat(UIO_SYSSPACE) expect that *buf always return memory which must be freed, regardless of the error. Assign NULL to *buf in case we are not going to allocate any memory due to invalid mode.

Test Plan

Reported and tested by: pho

Diff Detail

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

Event Timeline

kib retitled this revision from to Fix a regression in r310638..
kib updated this object.
kib edited the test plan for this revision. (Show Details)
kib added reviewers: jhb, trasz.
kib set the repository for this revision to rS FreeBSD src repository - subversion.
kib added a subscriber: pho.
jhb edited edge metadata.
This revision is now accepted and ready to land.Jan 4 2017, 3:46 PM
This revision was automatically updated to reflect the committed changes.