From 16d18d935d055b74e05f615c0325318a329a7fe1 Mon Sep 17 00:00:00 2001 From: Tom Sepez Date: Fri, 24 Aug 2018 19:45:09 +0000 Subject: Use span in more fxcodec code. There are also small tweaks in tests to ensure strict order of stack variable lifetimes. Change-Id: Ic9d5c6a2bdd378b517be627f8e29f725bafdc2ad Reviewed-on: https://pdfium-review.googlesource.com/41310 Reviewed-by: Lei Zhang Commit-Queue: Tom Sepez --- core/fxcodec/codec/ccodec_bmpmodule.cpp | 7 ++----- 1 file changed, 2 insertions(+), 5 deletions(-) (limited to 'core/fxcodec/codec/ccodec_bmpmodule.cpp') diff --git a/core/fxcodec/codec/ccodec_bmpmodule.cpp b/core/fxcodec/codec/ccodec_bmpmodule.cpp index f4bfa010dc..75e59edf2b 100644 --- a/core/fxcodec/codec/ccodec_bmpmodule.cpp +++ b/core/fxcodec/codec/ccodec_bmpmodule.cpp @@ -69,9 +69,6 @@ FX_FILESIZE CCodec_BmpModule::GetAvailInput(Context* pContext, return ctx->m_Bmp.GetAvailInput(avail_buf_ptr); } -void CCodec_BmpModule::Input(Context* pContext, - uint8_t* src_buf, - uint32_t src_size) { - auto* ctx = static_cast(pContext); - ctx->m_Bmp.SetInputBuffer(src_buf, src_size); +void CCodec_BmpModule::Input(Context* pContext, pdfium::span src_buf) { + static_cast(pContext)->m_Bmp.SetInputBuffer(src_buf); } -- cgit v1.2.3