Skip to content

Commit

Permalink
Apply suggestions
Browse files Browse the repository at this point in the history
Signed-off-by: tempate <[email protected]>
  • Loading branch information
Tempate committed Nov 7, 2023
1 parent aaab692 commit 4a0f594
Show file tree
Hide file tree
Showing 2 changed files with 3 additions and 2 deletions.
Original file line number Diff line number Diff line change
Expand Up @@ -112,7 +112,7 @@ class CommonWriter : public BaseWriter, public fastrtps::rtps::WriterListener
* @brief CommonWriter Listener callback when all the Readers have received a change.
*
* This method is called when all the Readers subscribed to a Topic acknowledge that they have received a change.
* It removes the change from the Writer's history if the Writer is volatile.
* It removes the change from the Writer's history if the Writer is best-effort or volatile.
*
* @param [in] ch the change that has been acknowledged by all the Readers.
*/
Expand Down
3 changes: 2 additions & 1 deletion ddspipe_participants/src/cpp/writer/rtps/CommonWriter.cpp
Original file line number Diff line number Diff line change
Expand Up @@ -129,7 +129,8 @@ void CommonWriter::onWriterChangeReceivedByAll(
fastrtps::rtps::RTPSWriter* /*writer*/,
fastrtps::rtps::CacheChange_t* change)
{
if (writer_qos_.m_durability.kind == fastdds::dds::VOLATILE_DURABILITY_QOS)
if (writer_qos_.m_reliability.kind == fastdds::dds::BEST_EFFORT_RELIABILITY_QOS ||
writer_qos_.m_durability.kind == fastdds::dds::VOLATILE_DURABILITY_QOS)
{
rtps_history_->remove_change_g(change);
}
Expand Down

0 comments on commit 4a0f594

Please sign in to comment.