I try to use modorn c++ to create FlowController like:
std::shared_ptr<DomainParticipant> participant;
participant = std::make_shared<DomainParticipant>(dds_param.domain(), domain_qos);
auto flowcontroller = std::make_shared<FlowController>(*participant, topic + "_flow_contoller", flowcontroller_prop);
...
participant.reset();
program will coredump in participant.reset(). if i use raw FlowController* poiter varable store the the FlowController obj without delete the pointer explicitly, the program exit normally. I want to know why? and the correct way to create FlowController?
why is there no FlowController Use Cases in Programming How-To's of RTI Connext Modern C++ API Version 6.1.0 like Version 5.1.0?
Probably unrelated, but you shouldn't declare dds Entities as pointers: https://community.rti.com/best-practices/modern-c-api-don’t-declare-entities-pointers
You can see an example here: https://github.com/rticommunity/rticonnextdds-examples/tree/master/examples/connext_dds/custom_flow_controller/c%2B%2B11
Thanks. the answer correct my usage of Entities.