[SERVER-64212] Coverity analysis defect 121638: Redundant test Created: 04/Mar/22  Updated: 27/Oct/23  Resolved: 09/Mar/22

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

Type: Bug Priority: Minor - P4
Reporter: Coverity Collector User Assignee: Mihai Andrei
Resolution: Gone away Votes: 0
Labels: coverity
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: PNG File Screen Shot 2022-03-04 at 9.49.54 AM.png    
Issue Links:
Depends
depends on SERVER-64117 Prevent $lookup pushdown when the lef... Closed
Problem/Incident
is caused by SERVER-62798 Use AutoGetCollectionMulti in MultiCo... Closed
Operating System: ALL
Sprint: QE 2022-03-07, QE 2022-03-21
Participants:

 Description   

Redundant test

By the time the program execution reaches the test of this condition there is only one possible outcome for the test. The code at the destination of this branch is not dead, either because this condition is always true or because there is at least one other branch that reaches it. Test always evaluates the same
/src/mongo/db/pipeline/pipeline_d.cpp:181: DEADCODE 121638 At condition "lookupFeatureFlagEnabled", the value of "lookupFeatureFlagEnabled" must be equal to 1.
/src/mongo/db/pipeline/pipeline_d.cpp:162: DEADCODE 121638 Condition "lookupFeatureFlagEnabled", taking true branch. Now the value of "lookupFeatureFlagEnabled" is equal to 1.
/src/mongo/db/pipeline/pipeline_d.cpp:181: DEADCODE 121638 The condition "lookupFeatureFlagEnabled" must be true.



 Comments   
Comment by Mihai Andrei [ 09/Mar/22 ]

Gone away underĀ https://github.com/mongodb/mongo/commit/8287a153f11a4c3906305512689cac46918022b9

Comment by Kyle Suarez [ 04/Mar/22 ]

CC mihai.andrei

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