From 928a75deca64a4046c9270cfa7e8759f43334769 Mon Sep 17 00:00:00 2001 From: Yannis Guyon Date: Fri, 21 Dec 2018 17:57:47 +0100 Subject: [PATCH] webp: Fix VP8LBitWriterClone() bug dst->cur_ was not set. The bug occurred only with several VP8LBitWriter instances (thread_level > 0) and in 32-bit (in 64-bit, src->cur_ was always 0 in VP8LBitWriterClone()). BUG=chromium:917029 Change-Id: I0d94a3d8e62b247fd616eebe1009868dc8a5ed2e --- src/utils/bit_writer_utils.c | 1 + 1 file changed, 1 insertion(+) diff --git a/src/utils/bit_writer_utils.c b/src/utils/bit_writer_utils.c index f4f476ce..7f83b4c8 100644 --- a/src/utils/bit_writer_utils.c +++ b/src/utils/bit_writer_utils.c @@ -248,6 +248,7 @@ int VP8LBitWriterClone(const VP8LBitWriter* const src, dst->bits_ = src->bits_; dst->used_ = src->used_; dst->error_ = src->error_; + dst->cur_ = dst->buf_ + current_size; return 1; }