From 8a60bdff131d28f7998785214bcc097206860aab Mon Sep 17 00:00:00 2001 From: Tom Henderson Date: Mon, 29 Jun 2020 16:23:14 -0700 Subject: [PATCH] network, internet: Clarify QueueDiscItem::Mark if item already marked --- src/internet/model/ipv4-queue-disc-item.h | 5 +++-- src/internet/model/ipv6-queue-disc-item.h | 5 +++-- src/network/utils/queue-item.h | 2 +- 3 files changed, 7 insertions(+), 5 deletions(-) diff --git a/src/internet/model/ipv4-queue-disc-item.h b/src/internet/model/ipv4-queue-disc-item.h index 52371a4b6..7ce1cda4e 100644 --- a/src/internet/model/ipv4-queue-disc-item.h +++ b/src/internet/model/ipv4-queue-disc-item.h @@ -77,8 +77,9 @@ public: virtual bool GetUint8Value (Uint8Values field, uint8_t &value) const; /** - * \brief Marks the packet by setting ECN_CE bits if the packet has ECN_ECT0 or ECN_ECT1 bits set - * \return true if the packet gets marked, false otherwise + * \brief Marks the packet by setting ECN_CE bits if the packet has + * ECN_ECT0 or ECN_ECT1 set. If ECN_CE is already set, returns true. + * \return true if the method results in a marked packet, false otherwise */ virtual bool Mark (void); diff --git a/src/internet/model/ipv6-queue-disc-item.h b/src/internet/model/ipv6-queue-disc-item.h index 4afe86c73..760ec492b 100644 --- a/src/internet/model/ipv6-queue-disc-item.h +++ b/src/internet/model/ipv6-queue-disc-item.h @@ -77,8 +77,9 @@ public: virtual bool GetUint8Value (Uint8Values field, uint8_t &value) const; /** - * \brief Marks the packet by setting ECN_CE bits if the packet has ECN_ECT0 or ECN_ECT1 bits set - * \return true if the packet gets marked, false otherwise + * \brief Marks the packet by setting ECN_CE bits if the packet has + * ECN_ECT0 or ECN_ECT1 set. If ECN_CE is already set, returns true. + * \return true if the method results in a marked packet, false otherwise */ virtual bool Mark (void); diff --git a/src/network/utils/queue-item.h b/src/network/utils/queue-item.h index d22b03ba2..65d2181af 100644 --- a/src/network/utils/queue-item.h +++ b/src/network/utils/queue-item.h @@ -211,7 +211,7 @@ public: /** * \brief Marks the packet as a substitute for dropping it, such as for Explicit Congestion Notification * - * \return true if the packet gets marked, false otherwise + * \return true if the packet is marked by this method or is already marked, false otherwise */ virtual bool Mark (void) = 0;