mirror of
https://github.com/Xevion/easy7zip.git
synced 2025-12-08 14:07:00 -06:00
15.05
This commit is contained in:
committed by
Kornel Lesiński
parent
0713a3ab80
commit
54490d51d5
@@ -75,11 +75,14 @@ HRESULT CCabBlockInStream::PreRead(ISequentialInStream *stream, UInt32 &packSize
|
||||
|
||||
STDMETHODIMP CCabBlockInStream::Read(void *data, UInt32 size, UInt32 *processedSize)
|
||||
{
|
||||
UInt32 rem = _size - _pos;
|
||||
if (size > rem)
|
||||
size = rem;
|
||||
memcpy(data, _buf + _pos, size);
|
||||
_pos += size;
|
||||
if (size != 0)
|
||||
{
|
||||
UInt32 rem = _size - _pos;
|
||||
if (size > rem)
|
||||
size = rem;
|
||||
memcpy(data, _buf + _pos, size);
|
||||
_pos += size;
|
||||
}
|
||||
if (processedSize)
|
||||
*processedSize = size;
|
||||
return S_OK;
|
||||
|
||||
Reference in New Issue
Block a user