From 58c2c144c5ac6a7397573d2f25d1ba9c79bc4f15 Mon Sep 17 00:00:00 2001 From: Lei Zhang Date: Tue, 19 Dec 2017 19:00:43 +0000 Subject: Remove some dead code. Change-Id: I8edb14c024860c66b5e6c014136393e71e38387d Reviewed-on: https://pdfium-review.googlesource.com/21570 Reviewed-by: Henrique Nakashima Commit-Queue: Lei Zhang --- core/fxcrt/cfx_binarybuf.cpp | 20 -------------------- 1 file changed, 20 deletions(-) (limited to 'core/fxcrt/cfx_binarybuf.cpp') diff --git a/core/fxcrt/cfx_binarybuf.cpp b/core/fxcrt/cfx_binarybuf.cpp index 3673fa58d4..1243593a77 100644 --- a/core/fxcrt/cfx_binarybuf.cpp +++ b/core/fxcrt/cfx_binarybuf.cpp @@ -12,11 +12,6 @@ CFX_BinaryBuf::CFX_BinaryBuf() : m_AllocStep(0), m_AllocSize(0), m_DataSize(0) {} -CFX_BinaryBuf::CFX_BinaryBuf(size_t size) - : m_AllocStep(0), m_AllocSize(size), m_DataSize(size) { - m_pBuffer.reset(FX_Alloc(uint8_t, size)); -} - CFX_BinaryBuf::~CFX_BinaryBuf() {} void CFX_BinaryBuf::Delete(size_t start_index, size_t count) { @@ -77,18 +72,3 @@ void CFX_BinaryBuf::AppendBlock(const void* pBuf, size_t size) { } m_DataSize += size; } - -void CFX_BinaryBuf::InsertBlock(size_t pos, const void* pBuf, size_t size) { - if (size <= 0) - return; - - ExpandBuf(size); - memmove(m_pBuffer.get() + pos + size, m_pBuffer.get() + pos, - m_DataSize - pos); - if (pBuf) { - memcpy(m_pBuffer.get() + pos, pBuf, size); - } else { - memset(m_pBuffer.get() + pos, 0, size); - } - m_DataSize += size; -} -- cgit v1.2.3