Merge "localisation: Release data from memory in LCStoreStaticArray::finishWrite"
authorjenkins-bot <jenkins-bot@gerrit.wikimedia.org>
Wed, 4 Sep 2019 21:53:34 +0000 (21:53 +0000)
committerGerrit Code Review <gerrit@wikimedia.org>
Wed, 4 Sep 2019 21:53:34 +0000 (21:53 +0000)
includes/cache/localisation/LCStoreStaticArray.php

index 5911656..53893bd 100644 (file)
@@ -121,6 +121,8 @@ class LCStoreStaticArray implements LCStore {
                        'Generated by LCStoreStaticArray.php -- do not edit!'
                );
                file_put_contents( $this->fname, $out );
+               // Release the data to manage the memory in rebuildLocalisationCache
+               unset( $this->data[$this->currentLang] );
                $this->currentLang = null;
                $this->fname = null;
        }