Skip to content

Commit 88ebea9

Browse files
Make sure callback_end tracepoint is triggered in AnyServiceCallback (#2670)
Signed-off-by: Christophe Bedard <[email protected]>
1 parent 1e6767a commit 88ebea9

File tree

1 file changed

+2
-0
lines changed

1 file changed

+2
-0
lines changed

rclcpp/include/rclcpp/any_service_callback.hpp

+2
Original file line numberDiff line numberDiff line change
@@ -165,11 +165,13 @@ class AnyServiceCallback
165165
if (std::holds_alternative<SharedPtrDeferResponseCallback>(callback_)) {
166166
const auto & cb = std::get<SharedPtrDeferResponseCallback>(callback_);
167167
cb(request_header, std::move(request));
168+
TRACETOOLS_TRACEPOINT(callback_end, static_cast<const void *>(this));
168169
return nullptr;
169170
}
170171
if (std::holds_alternative<SharedPtrDeferResponseCallbackWithServiceHandle>(callback_)) {
171172
const auto & cb = std::get<SharedPtrDeferResponseCallbackWithServiceHandle>(callback_);
172173
cb(service_handle, request_header, std::move(request));
174+
TRACETOOLS_TRACEPOINT(callback_end, static_cast<const void *>(this));
173175
return nullptr;
174176
}
175177
// auto response = allocate_shared<typename ServiceT::Response, Allocator>();

0 commit comments

Comments
 (0)