[CXX-1891] Coverity analysis defect 105008: Uninitialized scalar field Created: 16/Dec/19  Updated: 28/Oct/23  Resolved: 19/Aug/22

Status: Closed
Project: C++ Driver
Component/s: None
Affects Version/s: None
Fix Version/s: 3.7.0

Type: Bug Priority: Minor - P4
Reporter: Coverity Collector User Assignee: Ezra Chung
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified


 Description   

A scalar field is not initialized by the constructor

Defect 105008 (STATIC_C)
Checker UNINIT_CTOR (subcategory none)
File: /src/bsoncxx/types.hpp
Function mongocxx::v_noabi::options::change_stream::change_stream()
/src/bsoncxx/types.hpp, line: 561
The compiler-generated constructor for this class does not initialize "_start_at_operation_time.increment".

        uint32_t increment;

/src/bsoncxx/types.hpp, line: 562
The compiler-generated constructor for this class does not initialize "_start_at_operation_time.timestamp".

        uint32_t timestamp;



 Comments   
Comment by Ezra Chung [ 19/Aug/22 ]

PR: https://github.com/mongodb/mongo-cxx-driver/pull/885

Commit: https://github.com/mongodb/mongo-cxx-driver/commit/51e570163744f36f28a106967577369b65be3ea4

 

Generated at Wed Feb 07 22:04:14 UTC 2024 using Jira 9.7.1#970001-sha1:2222b88b221c4928ef0de3161136cc90c8356a66.