[SERVER-59571] Coverity analysis defect 120455: Uninitialized scalar field Created: 25/Aug/21  Updated: 27/Oct/23  Resolved: 02/Sep/21

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

Type: Bug Priority: Major - P3
Reporter: Coverity Collector User Assignee: Henrik Edin
Resolution: Works as Designed Votes: 0
Labels: coverity
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Operating System: ALL
Sprint: Execution Team 2021-09-20
Participants:

 Description   

Uninitialized scalar field

The field will contain an arbitrary value left over from earlier computations. A scalar field is not initialized by the constructor
/src/mongo/bson/util/bsoncolumn.h:152: UNINIT_CTOR 120455 Class member declaration for "_scaleIndex".
/src/mongo/bson/util/bsoncolumn.cpp:122: UNINIT_CTOR 120455 Non-static class member "_scaleIndex" is not initialized in this constructor nor in any functions that it calls.



 Comments   
Comment by Henrik Edin [ 02/Sep/21 ]

It will be initialized before used when reading a control byte.

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