MCPcopy Create free account
hub / github.com/TorqueGameEngines/Torque3D / closeFile

Method closeFile

Engine/source/core/util/zip/zipArchive.cpp:703–727  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

701}
702
703void ZipArchive::closeFile(Stream *stream)
704{
705 FilterStream *currentStream, *nextStream;
706
707 nextStream = dynamic_cast<FilterStream*>(stream);
708 while (nextStream)
709 {
710 currentStream = nextStream;
711 stream = currentStream->getStream();
712
713 currentStream->detachStream();
714
715 nextStream = dynamic_cast<FilterStream*>(stream);
716
717 delete currentStream;
718 }
719
720 ZipTempStream *tempStream = dynamic_cast<ZipTempStream *>(stream);
721 if(tempStream && (tempStream->getCentralDir()->mInternalFlags & CDFileOpen))
722 {
723 // [tom, 1/23/2007] This is a temporary file we are writing to
724 // so we need to update the relevant information in the header.
725 updateFile(tempStream);
726 }
727}
728
729//-----------------------------------------------------------------------------
730

Callers

nothing calls this directly

Calls 3

getStreamMethod · 0.45
detachStreamMethod · 0.45
getCentralDirMethod · 0.45

Tested by

no test coverage detected