Skip to content

Commit

Permalink
Refs #21121: Revision - minor changes 2
Browse files Browse the repository at this point in the history
Signed-off-by: cferreiragonz <[email protected]>
  • Loading branch information
cferreiragonz committed Jun 11, 2024
1 parent c7c210b commit befd466
Show file tree
Hide file tree
Showing 3 changed files with 4 additions and 7 deletions.
5 changes: 2 additions & 3 deletions include/fastdds/rtps/history/IPayloadPool.h
Original file line number Diff line number Diff line change
Expand Up @@ -70,10 +70,9 @@ class IPayloadPool
*
* @returns whether the operation succeeded or not
*
* @note @c data is received as reference to accommodate the case where several readers
* receive the same payload. If the payload has no owner, it means it is allocated on the stack of a
* @note If @c data has no owner, it means it is allocated on the stack of a
* reception thread, and a copy should be performed. If the ownership of @c data needs to be changed,
* a consecutive call to this method needs to be called with the arguments swapped, leveraging the
* a consecutive call to this method needs to be performed with the arguments swapped, leveraging the
* post-condition of this method which ensures that @c payload.payload_owner points to @c this.
*
* @post
Expand Down
3 changes: 1 addition & 2 deletions src/cpp/rtps/reader/StatefulReader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -646,8 +646,7 @@ bool StatefulReader::process_data_msg(
{
if (change->serializedPayload.payload_owner == nullptr)
{
change_to_add->serializedPayload.payload_owner->get_payload(change_to_add->serializedPayload,
change->serializedPayload);
payload_pool_->get_payload(change_to_add->serializedPayload, change->serializedPayload);
}
}
else
Expand Down
3 changes: 1 addition & 2 deletions src/cpp/rtps/reader/StatelessReader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -629,8 +629,7 @@ bool StatelessReader::process_data_msg(
{
if (change->serializedPayload.payload_owner == nullptr)
{
change_to_add->serializedPayload.payload_owner->get_payload(change_to_add->serializedPayload,
change->serializedPayload);
payload_pool_->get_payload(change_to_add->serializedPayload, change->serializedPayload);
}
}
else
Expand Down

0 comments on commit befd466

Please sign in to comment.