Only seek back to old position if the header has been flushed.
[core.git] / inc / classes / main / class_BaseFrameworkSystem.php
index be6499dc3f5d7e7a0cfa9beaff4199b913e5bdf7..033718d949958c02f9eb54fee8e5cfe9d24cb094 100644 (file)
@@ -3097,10 +3097,11 @@ class BaseFrameworkSystem extends stdClass implements FrameworkInterface {
                if ($flushHeader === TRUE) {
                        // Flush header
                        $this->flushFileHeader();
+
+                       // Seek to old position
+                       $this->seekToOldPosition();
                } // END - if
 
-               // Seek to old position
-               $this->seekToOldPosition();
                //* NOISY-DEBUG: */ self::createDebugInstance(__CLASS__)->debugOutput(sprintf('[%s:%d:] EXIT!', __METHOD__, __LINE__));
        }