Page MenuHomeFreeBSD

vidcontrol: improve error handling
AbandonedPublic

Authored by emaste on May 2 2016, 6:04 PM.
Tags
None
Referenced Files
Unknown Object (File)
Tue, May 7, 12:24 PM
Unknown Object (File)
Mar 22 2024, 3:40 PM
Unknown Object (File)
Feb 29 2024, 6:47 PM
Unknown Object (File)
Jan 19 2024, 1:23 AM
Unknown Object (File)
Jan 15 2024, 6:18 AM
Unknown Object (File)
Jan 15 2024, 1:01 AM
Unknown Object (File)
Jan 10 2024, 3:49 AM
Unknown Object (File)
Jan 2 2024, 4:19 AM
Subscribers

Details

Summary

We can just exit in the case of errors.

PR: 209078
Reported by: cturt@hardenedbsd.org

Diff Detail

Lint
Lint Skipped
Unit
Tests Skipped

Event Timeline

emaste retitled this revision from to vidcontrol: improve error handling.
emaste updated this object.
emaste edited the test plan for this revision. (Show Details)
emaste added a reviewer: cturt_hardenedbsd.org.

also free mappings in success case

ngie added a reviewer: ngie.
ngie added a subscriber: ngie.

This is going to increase the number of "false positives" with Coverity (err* with fopened FILE*), but the change LGTM.

This revision is now accepted and ready to land.May 2 2016, 6:48 PM
usr.sbin/vidcontrol/vidcontrol.c
458–459

Thank you for fixing this BTW :)..

This is going to increase the number of "false positives" with Coverity (err* with fopened FILE*)

I'm not sure exactly what you mean here, can you clarify?

This is going to increase the number of "false positives" with Coverity (err* with fopened FILE*)

I'm not sure exactly what you mean here, can you clarify?

I'll have to go back and look. IIRC, err* wasn't instrumented properly with Coverity and file descriptors and items after the call were marked as false positives.

Change in D8176 committed instead.