[SERVER-70861] Coverity analysis defect 134014: Uninitialized scalar field Created: 26/Oct/22  Updated: 29/Oct/23  Resolved: 24/Nov/22

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

Type: Bug Priority: Major - P3
Reporter: Coverity Collector User Assignee: Ruoxin Xu
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
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/db/exec/scoped_timer.h:62: UNINIT_CTOR 134014 Class member declaration for "_startTS".
/src/mongo/db/exec/scoped_timer.cpp:39: UNINIT_CTOR 134014 Non-static class member "_startTS" is not initialized in this constructor nor in any functions that it calls.



 Comments   
Comment by Githook User [ 22/Nov/22 ]

Author:

{'name': 'Ruoxin Xu', 'email': 'ruoxin.xu@mongodb.com', 'username': 'RuoxinXu'}

Message: SERVER-70861 Coverity analysis defect 134014: Uninitialized scalar field
Branch: master
https://github.com/mongodb/mongo/commit/8672f026dd4719a994c450e8deb84588d71e24fc

Generated at Thu Feb 08 06:17:20 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.