diff --git a/rmw_connextdds_common/include/rmw_connextdds/dds_api.hpp b/rmw_connextdds_common/include/rmw_connextdds/dds_api.hpp index 55a3a0b9..9fb701d9 100644 --- a/rmw_connextdds_common/include/rmw_connextdds/dds_api.hpp +++ b/rmw_connextdds_common/include/rmw_connextdds/dds_api.hpp @@ -48,8 +48,8 @@ enum RMW_Connext_MessageType struct RMW_Connext_WriteParams { - DDS_Time_t timestamp{DDS_TIME_INVALID}; - int64_t sequence_number{0}; + DDS_Time_t timestamp = DDS_TIME_INVALID; + int64_t sequence_number = 0L; }; RMW_CONNEXTDDS_PUBLIC extern const char * const RMW_CONNEXTDDS_ID; diff --git a/rmw_connextdds_common/include/rmw_connextdds/dds_api_rtime.hpp b/rmw_connextdds_common/include/rmw_connextdds/dds_api_rtime.hpp index d73b15af..b8e6cbd1 100644 --- a/rmw_connextdds_common/include/rmw_connextdds/dds_api_rtime.hpp +++ b/rmw_connextdds_common/include/rmw_connextdds/dds_api_rtime.hpp @@ -73,4 +73,9 @@ struct DDS_LifespanQosPolicy; // Not available function #define DDS_DataWriter_wait_for_acknowledgments(writer_, timeout_) DDS_RETCODE_UNSUPPORTED +#define DDS_Time_is_invalid(timePtr) \ + ((timePtr)->sec < 0) + +#define DDS_TIME_INVALID {-1L, 0UL} + #endif // RMW_CONNEXTDDS__DDS_API_RTIME_HPP_