Hi, I'm using Connext 5.3.1. I get the following runtime error. What could be the issue?
DDS_Topic_createI:!create presentation topic
terminate called after throwing an instance of 'dds::core::Error'
what(): Failed to create Topic
My code is like this
code
dds::domain::DomainParticipant existing_participant = dds::domain::find(DDS_DOMAIN_ID);
if (existing_participant != dds::core::null) {
dds::pub::Publisher publisher = dds::pub::Publisher(existing_participant);
dds::topic::Topic<foo> pub_topic (existing_participant, "foo");
...
}
In reply to my earlier post, I realised my mistake. It's because I'm creating an identical topic which had been created earlier. By using this code instead, the error is gone
code dds::topic::Topic<M3CommandAll> pub_topic =
dds::topic::find<dds::topic::Topic<M3CommandAll> >(existing_participant, "M3CommandAll");