eclipse-cyclonedds / cyclonedds-cxx

Other
96 stars 75 forks source link

Do not throw an exception on times before 19700101 #503

Closed eboasson closed 3 months ago

eboasson commented 3 months ago

This stops throwing the C++ wrapper from throwing an exception in the dds:core::Time class on trying to construct a time stamp prior to the 00:00:00 UTC on 1 January 1970. There is no reason to do that and it makes it vulnerable to receiving samples with earlier time stamps.

It is tricky to test: Cyclone won't allow writing these. I've tested it in a rather convoluted manner by hand ...