Reported by: Coverity (CID 1018472, 1018474)
MFC after: 1 week
Sponsored by: Klara, Inc.
Details
Details
- Reviewers
emaste imp kevans - Group Reviewers
Klara - Commits
- rG96e68c393f65: tzcode: Avoid memory leak if pthread_setspecific() fails.
Diff Detail
Diff Detail
- Repository
- rG FreeBSD src repository
- Lint
Lint Not Applicable - Unit
Tests Not Applicable
Event Timeline
Comment Actions
This looks fine, but I'd suggest a better commit message explaining the Coverity issues would be helpful
Comment Actions
What needs explaining? Coverity correctly flagged that the code doesn't check the outcome of the _pthread_setspecific() calls, so I added checks.
Comment Actions
Check outcome and cleanup on failure then. Since it's more than just a check and return...
Again, just a suggestion to make it better...