diff options
author | Tom Sepez <tsepez@chromium.org> | 2016-02-19 14:28:12 -0800 |
---|---|---|
committer | Tom Sepez <tsepez@chromium.org> | 2016-02-19 14:28:12 -0800 |
commit | ffc26c26f0ab004fbdb05195e1686d7f33983b06 (patch) | |
tree | 9bc8f16d1bc7dc32e924fb5c173a561c03eac3d9 /core/src/fxcodec | |
parent | 11d33361e95d5ea61ee43e4261fa8f53aa372731 (diff) | |
download | pdfium-ffc26c26f0ab004fbdb05195e1686d7f33983b06.tar.xz |
Revert "Use safe arithmentic in CFX_BinaryBuf::ExpandBuf."
This reverts commit 78353d5dbc0b0c9b2d6946005439a51efa7d108c.
Reason for revert Failed tests.
TBR=thestig@chromium.org
Review URL: https://codereview.chromium.org/1719493002 .
Diffstat (limited to 'core/src/fxcodec')
-rw-r--r-- | core/src/fxcodec/codec/fx_codec_fax.cpp | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/core/src/fxcodec/codec/fx_codec_fax.cpp b/core/src/fxcodec/codec/fx_codec_fax.cpp index 36b92f06ff..cacbc71456 100644 --- a/core/src/fxcodec/codec/fx_codec_fax.cpp +++ b/core/src/fxcodec/codec/fx_codec_fax.cpp @@ -799,8 +799,9 @@ void CCodec_FaxEncoder::Encode(uint8_t*& dest_buf, FX_DWORD& dest_size) { if (dest_bitpos) { m_DestBuf.AppendByte(last_byte); } + dest_buf = m_DestBuf.GetBuffer(); dest_size = m_DestBuf.GetSize(); - dest_buf = m_DestBuf.DetachBuffer(); + m_DestBuf.DetachBuffer(); } FX_BOOL CCodec_FaxModule::Encode(const uint8_t* src_buf, int width, |