diff --git a/examples/cpp/xtypes/PublisherApp.cpp b/examples/cpp/xtypes/PublisherApp.cpp index b4ac99fced6..52c4006b42c 100644 --- a/examples/cpp/xtypes/PublisherApp.cpp +++ b/examples/cpp/xtypes/PublisherApp.cpp @@ -242,6 +242,7 @@ DynamicType::_ref_type PublisherApp::create_type( { std::cout << "Error getting dynamic type \"HelloWorld\"." << std::endl; + return nullptr; } } else