From 44bb2c82870f83776eb26d41aeb9defbee97b102 Mon Sep 17 00:00:00 2001 From: Noel Grandin Date: Wed, 16 Oct 2024 11:23:05 +0200 Subject: loplugin:unusedfields Change-Id: If05b87f1e6c19b15b03b2695921a582e078d0f1a Reviewed-on: https://gerrit.libreoffice.org/c/core/+/175011 Reviewed-by: Noel Grandin Tested-by: Jenkins --- package/source/zipapi/Inflater.cxx | 9 +-------- 1 file changed, 1 insertion(+), 8 deletions(-) (limited to 'package/source') diff --git a/package/source/zipapi/Inflater.cxx b/package/source/zipapi/Inflater.cxx index acabee88fb45..5a09415abe6c 100644 --- a/package/source/zipapi/Inflater.cxx +++ b/package/source/zipapi/Inflater.cxx @@ -136,10 +136,8 @@ sal_Int32 Inflater::doInflateBytes (Sequence < sal_Int8 > &rBuffer, sal_Int32 n InflaterBytes::InflaterBytes(bool bNoWrap) : bFinished(false), - bNeedDict(false), nOffset(0), nLength(0), - nLastInflateError(0), sInBuffer(nullptr) { pStream.reset(new z_stream); @@ -201,12 +199,9 @@ sal_Int32 InflaterBytes::doInflateBytes (sal_Int8* pOutBuffer, sal_Int32 nNewOff { if ( !pStream ) { - nLastInflateError = Z_STREAM_ERROR; return 0; } - nLastInflateError = 0; - pStream->next_in = reinterpret_cast( sInBuffer + nOffset ); pStream->avail_in = nLength; pStream->next_out = reinterpret_cast < unsigned char* > ( pOutBuffer + nNewOffset ); @@ -229,15 +224,13 @@ sal_Int32 InflaterBytes::doInflateBytes (sal_Int8* pOutBuffer, sal_Int32 nNewOff return nNewLength - pStream->avail_out; case Z_NEED_DICT: - bNeedDict = true; nOffset += nLength - pStream->avail_in; nLength = pStream->avail_in; return 0; default: // it is no error, if there is no input or no output - if ( nLength && nNewLength ) - nLastInflateError = nResult; + break; } return 0; -- cgit v1.2.3