Skip to content

Commit 399b5f7

Browse files
committed
Update comments.
Incidentally, this also reruns the flaky test suite, which seems to be using the real DDS middleware and to be prone to cross-talk. Signed-off-by: Steve Wolter <[email protected]>
1 parent fc513d2 commit 399b5f7

File tree

1 file changed

+6
-1
lines changed

1 file changed

+6
-1
lines changed

rclcpp/include/rclcpp/allocator/allocator_common.hpp

+6-1
Original file line numberDiff line numberDiff line change
@@ -64,7 +64,9 @@ void * retyped_reallocate(void * untyped_pointer, size_t size, void * untyped_al
6464

6565
} // namespace allocator
6666

67-
// Convert a std::allocator_traits-formatted Allocator into an rcl allocator
67+
// Deprecated: Generic converter from C++ allocator into RCL allocator.
68+
// This allocator overallocates memory by 100x and invokes UB on free,
69+
// see #1254.
6870
template<typename Alloc>
6971
rcl_allocator_t get_rcl_allocator(Alloc & allocator)
7072
{
@@ -80,6 +82,9 @@ rcl_allocator_t get_rcl_allocator(Alloc & allocator)
8082
return rcl_allocator;
8183
}
8284

85+
// Builds the RCL default allocator for the C++ standard allocator.
86+
// This assumes that the user intent behind both allocators is the
87+
// same: Using system malloc for allocation.
8388
template<typename T>
8489
rcl_allocator_t get_rcl_allocator(std::allocator<T> & allocator)
8590
{

0 commit comments

Comments
 (0)