[SERVER-61965] Coverity analysis defect 121236: Unchecked return value Created: 09/Dec/21  Updated: 29/Oct/23  Resolved: 04/Jan/22

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

Type: Improvement Priority: Minor - P4
Reporter: Coverity Collector User Assignee: Anna Wawrzyniak
Resolution: Fixed Votes: 0
Labels: coverity, neweng
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: PNG File Screen Shot 2021-12-09 at 9.48.06 AM.png    
Issue Links:
Duplicate
is duplicated by SERVER-61966 Coverity analysis defect 121236: Unch... Closed
Backwards Compatibility: Fully Compatible
Sprint: QE 2021-12-27, QE 2022-01-10
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/exec/sbe/stages/hash_agg.cpp:94: CHECKED_RETURN 121236 Calling "restore" without checking return value (as is done elsewhere 12 out of 23 times).



 Comments   
Comment by Githook User [ 18/Dec/21 ]

Author:

{'name': 'Anna Wawrzyniak', 'email': 'anna.wawrzyniak@mongodb.com', 'username': 'anna-wawrzyniak'}

Message: SERVER-61965 Add assertion in HashAggStage to fail when cursor restore is not successful.
Branch: master
https://github.com/mongodb/mongo/commit/857e5ff84b57167abcfb875c56a3cda1464de563

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