Page MenuHomeFreeBSD

Fix misc Coverity defects in camdd(8)
ClosedPublic

Authored by asomers on Jan 18 2017, 10:51 PM.
Tags
None
Referenced Files
F106085225: D9237.diff
Wed, Dec 25, 3:49 AM
Unknown Object (File)
Wed, Dec 11, 2:30 PM
Unknown Object (File)
Mon, Dec 9, 5:38 PM
Unknown Object (File)
Fri, Dec 6, 1:51 AM
Unknown Object (File)
Oct 16 2024, 8:29 PM
Unknown Object (File)
Oct 5 2024, 1:37 AM
Unknown Object (File)
Sep 18 2024, 10:33 PM
Unknown Object (File)
Sep 15 2024, 12:03 PM
Subscribers

Details

Summary

Fix misc Coverity defects in camdd(8)

CID 1341620 Fix a small memory leak
CID 1341630 Though this is technically a false positive, rearrange the

		code for clarity.

CID 1341635 Eliminate dead code
CID 1368663 Fix a double mutex unlock in the error path

Also:

  • Use sig_atomic_t for variables accessed from signal handlers
  • Don't conditionalize free(3) on its argument being non-null
Test Plan

Ken, can you please test it? I'm not sure how to test it to get full coverage.

Diff Detail

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

Event Timeline

asomers retitled this revision from to Fix misc Coverity defects in camdd(8).
asomers updated this object.
asomers edited the test plan for this revision. (Show Details)
asomers added a reviewer: ken.
ken edited edge metadata.

Okay, I tested most of the paths affected in the patch and things look good.

This revision is now accepted and ready to land.Jan 20 2017, 9:00 PM
This revision was automatically updated to reflect the committed changes.