From 07c720fdaa74d214b08b4888abaee3c09ce074de Mon Sep 17 00:00:00 2001 From: Roland Haeder Date: Sun, 18 May 2014 11:27:59 +0200 Subject: [PATCH] Always read file header. MIME-Version: 1.0 Content-Type: text/plain; charset=utf8 Content-Transfer-Encoding: 8bit Signed-off-by: Roland Häder --- .../main/stacker/file/class_BaseFileStack.php | 12 +++++++----- 1 file changed, 7 insertions(+), 5 deletions(-) diff --git a/inc/classes/main/stacker/file/class_BaseFileStack.php b/inc/classes/main/stacker/file/class_BaseFileStack.php index b4a91330..c768db3e 100644 --- a/inc/classes/main/stacker/file/class_BaseFileStack.php +++ b/inc/classes/main/stacker/file/class_BaseFileStack.php @@ -405,16 +405,18 @@ class BaseFileStack extends BaseStacker { $this->setIteratorInstance($iteratorInstance); // Is the file's header initialized? - if ($this->isFileHeaderInitialized()) { - // Then load it - $this->readFileHeader(); - } else { + if (!$this->isFileHeaderInitialized()) { // No, then create it (which may pre-allocate the stack) $this->createFileHeader(); // And pre-allocate a bit $this->preAllocateFile(); - } + } // END - if + + // Load the file header + $this->readFileHeader(); + + // Try to read file stack to speed up its processing. } /** -- 2.39.2