[SERVER-31911] Remove default constructor for UUID class Created: 10/Nov/17  Updated: 30/Oct/23  Resolved: 05/Jan/18

Status: Closed
Project: Core Server
Component/s: Storage
Affects Version/s: None
Fix Version/s: 3.6.3, 3.7.1

Type: Improvement Priority: Minor - P4
Reporter: Geert Bosch Assignee: Geert Bosch
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
Backports
Duplicate
is duplicated by SERVER-32537 Potential use of an uninitialized UUI... Closed
Backwards Compatibility: Fully Compatible
Backport Requested:
v3.6
Sprint: Storage 2018-01-01, Storage 2018-01-15
Participants:

 Description   

Having a default constructor can easily lead to accidentally using duplicate UUID values. For example, looking up a UUID in a map using operator[] will return a default constructed value.



 Comments   
Comment by Githook User [ 10/Jan/18 ]

Author:

{'email': 'geert@mongodb.com', 'name': 'Geert Bosch', 'username': 'GeertBosch'}

Message: SERVER-31911 make UUID constructor private

(cherry picked from commit e0c177cbb21110a5f18f920d5ec08e375b303157)
Branch: v3.6
https://github.com/mongodb/mongo/commit/d65e2699e78f533942cf643ba9777e278fc28593

Comment by Githook User [ 05/Jan/18 ]

Author:

{'name': 'Geert Bosch', 'username': 'GeertBosch', 'email': 'geert@mongodb.com'}

Message: SERVER-31911 make UUID constructor private
Branch: master
https://github.com/mongodb/mongo/commit/e0c177cbb21110a5f18f920d5ec08e375b303157

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