summaryrefslogtreecommitdiffstats
path: root/src/libs/3rdparty/7zip/win/CPP/7zip/Archive/Common/DummyOutStream.cpp
blob: 7c4f54879decc1ab2cec1d4f4c378b4f3b1435cf (plain)
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
// DummyOutStream.cpp

#include "StdAfx.h"

#include "DummyOutStream.h"

STDMETHODIMP CDummyOutStream::Write(const void *data, UInt32 size, UInt32 *processedSize)
{
  UInt32 realProcessedSize = size;
  HRESULT res = S_OK;
  if (_stream)
    res = _stream->Write(data, size, &realProcessedSize);
  _size += realProcessedSize;
  if (processedSize)
    *processedSize = realProcessedSize;
  return res;
}