-
Type:
Bug
-
Resolution: Done
-
Priority:
Major - P3
-
Affects Version/s: None
-
Component/s: Internal Code, Replication
-
None
-
Fully Compatible
-
ALL
-
None
-
0
-
None
-
None
-
None
-
None
-
None
-
None
The OpTime class assumes that it can dereference a casted pointer to its first uint32_t data member and read both data members out as a combined uint64_t. This is undefined behavior and is an aliasing violation.
In addition, OpTime has a specified memory ordering but does not use endian conversion primitives to ensure that it is properly serialized when written to the network or stable storage.