Skip to content

Commit

Permalink
Refs 12758. Fixing assertion on WriterProxy logic. If we only notify …
Browse files Browse the repository at this point in the history
…fragmented DATA reception on completion we should only notify removal of fully assembled samples.

Signed-off-by: Miguel Barro <miguelbarro@eprosima.com>
  • Loading branch information
Miguel Barro committed Nov 29, 2021
1 parent 6d45d1d commit ffd86b2
Showing 1 changed file with 2 additions and 3 deletions.
5 changes: 2 additions & 3 deletions src/cpp/rtps/reader/StatefulReader.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -754,15 +754,14 @@ bool StatefulReader::change_removed_by_history(
{
std::lock_guard<RecursiveTimedMutex> guard(mp_mutex);

if (is_alive_)
if (is_alive_ && a_change->is_fully_assembled())
{
if (wp != nullptr || matched_writer_lookup(a_change->writerGUID, &wp))
{
wp->change_removed_from_history(a_change->sequenceNumber);
}

if (a_change->is_fully_assembled() &&
!a_change->isRead &&
if (!a_change->isRead &&
get_last_notified(a_change->writerGUID) >= a_change->sequenceNumber)
{
if (0 < total_unread_)
Expand Down

0 comments on commit ffd86b2

Please sign in to comment.