aboutsummaryrefslogtreecommitdiffstats
path: root/Alc
diff options
context:
space:
mode:
authorChris Robinson <[email protected]>2018-12-27 15:05:12 -0800
committerChris Robinson <[email protected]>2018-12-27 15:05:12 -0800
commit515edc3deea8ba2661cb86571410fdd9a8eae158 (patch)
treef6226ab416907070bf8d79ac637ac121ee5c4ded /Alc
parentf2c2b7c5383ddd999b56f28730258f270b0d2576 (diff)
Fix ring buffer vector methods
Diffstat (limited to 'Alc')
-rw-r--r--Alc/ringbuffer.cpp6
1 files changed, 3 insertions, 3 deletions
diff --git a/Alc/ringbuffer.cpp b/Alc/ringbuffer.cpp
index 767db246..791fff63 100644
--- a/Alc/ringbuffer.cpp
+++ b/Alc/ringbuffer.cpp
@@ -192,7 +192,7 @@ void RingBuffer::writeAdvance(size_t cnt) noexcept
}
-ll_ringbuffer_data_pair RingBuffer::getWriteVector() const noexcept
+ll_ringbuffer_data_pair RingBuffer::getReadVector() const noexcept
{
ll_ringbuffer_data_pair ret;
@@ -205,7 +205,7 @@ ll_ringbuffer_data_pair RingBuffer::getWriteVector() const noexcept
const size_t cnt2{r + free_cnt};
if(cnt2 > mSizeMask+1)
{
- /* Two part vector: the rest of the buffer after the current write ptr,
+ /* Two part vector: the rest of the buffer after the current read ptr,
* plus some from the start of the buffer. */
ret.first.buf = const_cast<char*>(&mBuffer[r*mElemSize]);
ret.first.len = mSizeMask+1 - r;
@@ -224,7 +224,7 @@ ll_ringbuffer_data_pair RingBuffer::getWriteVector() const noexcept
return ret;
}
-ll_ringbuffer_data_pair RingBuffer::getReadVector() const noexcept
+ll_ringbuffer_data_pair RingBuffer::getWriteVector() const noexcept
{
ll_ringbuffer_data_pair ret;