Welcome to mirror list, hosted at ThFree Co, Russian Federation.

github.com/kornelski/7z.git - Unnamed repository; edit this file 'description' to name the repository.
summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
Diffstat (limited to 'CPP/7zip/Archive/Common/OutStreamWithCRC.h')
-rwxr-xr-xCPP/7zip/Archive/Common/OutStreamWithCRC.h17
1 files changed, 7 insertions, 10 deletions
diff --git a/CPP/7zip/Archive/Common/OutStreamWithCRC.h b/CPP/7zip/Archive/Common/OutStreamWithCRC.h
index a8791288..eaeecde7 100755
--- a/CPP/7zip/Archive/Common/OutStreamWithCRC.h
+++ b/CPP/7zip/Archive/Common/OutStreamWithCRC.h
@@ -15,27 +15,24 @@ class COutStreamWithCRC:
public ISequentialOutStream,
public CMyUnknownImp
{
-public:
- MY_UNKNOWN_IMP
-
- STDMETHOD(Write)(const void *data, UInt32 size, UInt32 *processedSize);
-private:
CMyComPtr<ISequentialOutStream> _stream;
UInt64 _size;
UInt32 _crc;
- bool _calculateCrc;
+ bool _calculate;
public:
+ MY_UNKNOWN_IMP
+ STDMETHOD(Write)(const void *data, UInt32 size, UInt32 *processedSize);
void SetStream(ISequentialOutStream *stream) { _stream = stream; }
- void Init(bool calculateCrc = true)
+ void ReleaseStream() { _stream.Release(); }
+ void Init(bool calculate = true)
{
_size = 0;
- _calculateCrc = calculateCrc;
+ _calculate = calculate;
_crc = CRC_INIT_VAL;
}
- void ReleaseStream() { _stream.Release(); }
+ void InitCRC() { _crc = CRC_INIT_VAL; }
UInt64 GetSize() const { return _size; }
UInt32 GetCRC() const { return CRC_GET_DIGEST(_crc); }
- void InitCRC() { _crc = CRC_INIT_VAL; }
};
#endif