summaryrefslogtreecommitdiff
path: root/encoders
diff options
context:
space:
mode:
Diffstat (limited to 'encoders')
-rw-r--r--encoders/vorbis_encoder.cpp2
1 files changed, 1 insertions, 1 deletions
diff --git a/encoders/vorbis_encoder.cpp b/encoders/vorbis_encoder.cpp
index dc8f34a..3704123 100644
--- a/encoders/vorbis_encoder.cpp
+++ b/encoders/vorbis_encoder.cpp
@@ -108,7 +108,7 @@ std::size_t VorbisEncoder::read(char* buf, std::size_t buf_size) {
// run until we have a page or reached end of stream
while(written == 0 && !ogg_page_eos(&og)) {
- written += encode(buf+written, buf_size-written);
+ written = encode(buf, buf_size);
}
return written;