[SERVER-51837] Coverity analysis defect 116502: Unchecked return value Created: 26/Oct/20  Updated: 29/Oct/23  Resolved: 04/Nov/20

Status: Closed
Project: Core Server
Component/s: Security
Affects Version/s: None
Fix Version/s: 4.9.0

Type: Bug Priority: Major - P3
Reporter: Coverity Collector User Assignee: Sara Golemon
Resolution: Fixed Votes: 0
Labels: coverity
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Depends
is depended on by SERVER-51838 Coverity analysis defect 116503: Unch... Closed
Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Security 2020-11-16
Participants:

 Description   

Unchecked return value

If the function returns an error value, the error value may be mistaken for a normal value. Value returned from a function is not checked for errors before being used
/src/mongo/db/auth/authz_manager_external_state_local.cpp:597: CHECKED_RETURN 116502 Calling "addPrivilegesForBuiltinRole" without checking return value (as is done elsewhere 2 out of 4 times).



 Comments   
Comment by Githook User [ 04/Nov/20 ]

Author:

{'name': 'Sara Golemon', 'email': 'sara.golemon@mongodb.com', 'username': 'sgolemon'}

Message: SERVER-51837 addPrivilegesForBuiltinRole should never fail with a builtin role
Branch: master
https://github.com/mongodb/mongo/commit/4196c19e115d8f5d65d5cb327561ae7369d975f4

Generated at Thu Feb 08 05:26:34 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.