From: Ramana Radhakrishnan Date: Tue, 5 May 2020 23:47:10 +0000 (+0100) Subject: [PATCH] [ring_buffer.h] Improve commentary for RingBuffer (#5518) X-Git-Tag: upstream/0.7.0~792 X-Git-Url: http://review.tizen.org/git/?a=commitdiff_plain;h=7cbc0ca1d16664ec53d9489f982d7b83bfa8bb60;p=platform%2Fupstream%2Ftvm.git [PATCH] [ring_buffer.h] Improve commentary for RingBuffer (#5518) bytes_available refers to the number of bytes used in the ring buffer. At the same time, fix a typo. --- diff --git a/src/support/ring_buffer.h b/src/support/ring_buffer.h index 7a1bcb6..d3227ad 100644 --- a/src/support/ring_buffer.h +++ b/src/support/ring_buffer.h @@ -149,7 +149,7 @@ class RingBuffer { bytes_available_ += size; } /*! - * \brief Writen data into the buffer by give it a non-blocking callback function. + * \brief Written data into the buffer by give it a non-blocking callback function. * * \param frecv A receive function handle * \param max_nbytes Maximum number of bytes can write. @@ -180,9 +180,9 @@ class RingBuffer { private: // buffer head size_t head_ptr_{0}; - // number of bytes in the buffer. + // number of bytes occupied in the buffer. size_t bytes_available_{0}; - // The internald ata ring. + // The internal data ring. std::vector ring_; }; } // namespace support