mirror of
https://github.com/ultimatepp/ultimatepp.git
synced 2026-07-11 22:03:01 -06:00
uppsrc: docs & removed #ifdef MTs
git-svn-id: svn://ultimatepp.org/upp/trunk@13925 f0d560ea-af0d-0410-9eb7-867de7ffcac7
This commit is contained in:
parent
8005b4dfde
commit
58e0fdebaf
22 changed files with 49 additions and 132 deletions
|
|
@ -7,10 +7,8 @@ void sCompressStreamCopy_(Stream& out, Stream& in, Gate<int64, int64> progress,
|
|||
static int64 sZstdCompress(Stream& out, Stream& in, int64 size, Gate<int64, int64> progress, bool co)
|
||||
{
|
||||
ZstdCompressStream outs(out);
|
||||
#ifdef _MULTITHREADED
|
||||
if(co)
|
||||
outs.Co();
|
||||
#endif
|
||||
sCompressStreamCopy_(outs, in, progress, in, size);
|
||||
outs.Close();
|
||||
if(!out.IsError() && !outs.IsError())
|
||||
|
|
@ -21,10 +19,8 @@ static int64 sZstdCompress(Stream& out, Stream& in, int64 size, Gate<int64, int6
|
|||
static int64 sZstdDecompress(Stream& out, Stream& in, int64 size, Gate<int64, int64> progress, bool co)
|
||||
{
|
||||
ZstdDecompressStream ins(in);
|
||||
#ifdef _MULTITHREADED
|
||||
if(co)
|
||||
ins.Co();
|
||||
#endif
|
||||
sCompressStreamCopy_(out, ins, progress, in, size);
|
||||
ins.Close();
|
||||
if(!out.IsError() && !ins.IsError())
|
||||
|
|
@ -66,8 +62,6 @@ String ZstdDecompress(const String& s, Gate<int64, int64> progress)
|
|||
return ZstdDecompress(~s, s.GetLength(), progress);
|
||||
}
|
||||
|
||||
#ifdef _MULTITHREADED
|
||||
|
||||
int64 CoZstdCompress(Stream& out, Stream& in, Gate<int64, int64> progress)
|
||||
{
|
||||
return sZstdCompress(out, in, in.GetLeft(), progress, true);
|
||||
|
|
@ -102,6 +96,4 @@ String CoZstdDecompress(const String& s, Gate<int64, int64> progress)
|
|||
return CoZstdDecompress(~s, s.GetLength(), progress);
|
||||
}
|
||||
|
||||
#endif
|
||||
|
||||
};
|
||||
Loading…
Add table
Add a link
Reference in a new issue