mirror of
https://github.com/TorqueGameEngines/Torque3D.git
synced 2026-02-21 15:43:45 +00:00
Clone file handle for concurrent zip access.
This commit is contained in:
parent
64c9667bad
commit
e808fc4407
2 changed files with 4 additions and 1 deletions
|
|
@ -85,7 +85,7 @@ void ZipCryptRStream::setPassword(const char *password)
|
|||
|
||||
bool ZipCryptRStream::attachStream(Stream* io_pSlaveStream)
|
||||
{
|
||||
mStream = io_pSlaveStream;
|
||||
mStream = io_pSlaveStream->clone();
|
||||
mStreamStartPos = mStream->getPosition();
|
||||
|
||||
// [tom, 12/20/2005] Encrypted zip files have an extra 12 bytes
|
||||
|
|
|
|||
|
|
@ -58,7 +58,10 @@ bool ZipSubRStream::attachStream(Stream* io_pSlaveStream)
|
|||
AssertFatal(io_pSlaveStream != NULL, "NULL Slave stream?");
|
||||
AssertFatal(m_pStream == NULL, "Already attached!");
|
||||
|
||||
m_pStream = io_pSlaveStream->clone();
|
||||
if (!m_pStream)
|
||||
m_pStream = io_pSlaveStream;
|
||||
|
||||
m_originalSlavePosition = io_pSlaveStream->getPosition();
|
||||
m_uncompressedSize = 0;
|
||||
m_currentPosition = 0;
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue