Page MenuHomeFreeBSD

Fix various Coverity issues in savecore
ClosedPublic

Authored by asomers on Oct 23 2015, 3:24 PM.
Tags
None
Referenced Files
F105519151: D3991.diff
Tue, Dec 17, 4:46 AM
Unknown Object (File)
Wed, Nov 27, 5:23 PM
Unknown Object (File)
Oct 28 2024, 9:40 PM
Unknown Object (File)
Oct 28 2024, 8:24 AM
Unknown Object (File)
Sep 21 2024, 5:14 AM
Unknown Object (File)
Sep 11 2024, 5:04 AM
Unknown Object (File)
Sep 8 2024, 6:08 PM
Unknown Object (File)
Sep 8 2024, 3:22 PM
Subscribers

Details

Summary

Fix various Coverity issues in savecore.c:
CID1009429: Fix unchecked return value from lseek while clearing dump
CID1007781: Fix file descriptor leak in DoFile
CID1007261: Don't send potentially unterminated string to syslog(3)

Test Plan

Create and save dumps with various savecore options

Diff Detail

Repository
rS FreeBSD src repository - subversion
Lint
Lint Passed
Unit
No Test Coverage
Build Status
Buildable 912
Build 912: arc lint + arc unit

Event Timeline

asomers retitled this revision from to Fix various Coverity issues in savecore.
asomers updated this object.
asomers edited the test plan for this revision. (Show Details)
asomers added a reviewer: markj.
markj edited edge metadata.
markj added inline comments.
sbin/savecore/savecore.c
731

Missing parens for sizeof. It also feels a bit unusual to me to have the write() call on the RHS here.

This revision is now accepted and ready to land.Oct 23 2015, 5:53 PM
This revision was automatically updated to reflect the committed changes.