[SERVER-50126] Coverity analysis defect 116111: Uninitialized pointer field Created: 05/Aug/20  Updated: 29/Oct/23  Resolved: 11/Aug/20

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

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

Backwards Compatibility: Fully Compatible
Operating System: ALL
Sprint: Execution Team 2020-08-24
Participants:

 Description   

Uninitialized pointer field

The pointer field will point to an arbitrary memory location, any attempt to write may cause corruption. A pointer field is not initialized in the constructor
/src/mongo/db/index/skipped_record_tracker.h:85: UNINIT_CTOR 116111 Class member declaration for "_indexCatalogEntry".
/src/mongo/db/index/skipped_record_tracker.cpp:46: UNINIT_CTOR 116111 Non-static class member "_indexCatalogEntry" is not initialized in this constructor nor in any functions that it calls.



 Comments   
Comment by Githook User [ 11/Aug/20 ]

Author:

{'name': 'Samy Lanka', 'email': 'samy.lanka@mongodb.com', 'username': 'lankas'}

Message: SERVER-50126 Use constructor delegation for skipped record tracker
Branch: master
https://github.com/mongodb/mongo/commit/7188dadfb837f4f27f85304430b2eacd93add99a

Comment by Samyukta Lanka [ 11/Aug/20 ]

code review: https://mongodbcr.appspot.com/641060001/

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