X-Git-Url: http://git.heureux-cyclage.org/?a=blobdiff_plain;f=maintenance%2Fincludes%2FTextPassDumper.php;h=00d7c90618e2d54e07ea57524d9af87942e7c2b6;hb=9c70ca60ff08060d5b32867f762d96dbc4314010;hp=04767fa900ace9b25ded79a8c00131a0d4d2ed4e;hpb=b04bef1d0488bc122bcc412a185b5d5c8101460a;p=lhc%2Fweb%2Fwiklou.git diff --git a/maintenance/includes/TextPassDumper.php b/maintenance/includes/TextPassDumper.php index 04767fa900..00d7c90618 100644 --- a/maintenance/includes/TextPassDumper.php +++ b/maintenance/includes/TextPassDumper.php @@ -64,7 +64,8 @@ class TextPassDumper extends BackupDumper { protected $bufferSize = 524288; // In bytes. Maximum size to read from the stub in on go. - protected $php = "php"; + /** @var array */ + protected $php = []; protected $spawn = false; /** @@ -73,14 +74,14 @@ class TextPassDumper extends BackupDumper { protected $spawnProc = false; /** - * @var bool|resource + * @var resource */ - protected $spawnWrite = false; + protected $spawnWrite; /** - * @var bool|resource + * @var resource */ - protected $spawnRead = false; + protected $spawnRead; /** * @var bool|resource @@ -96,6 +97,7 @@ class TextPassDumper extends BackupDumper { protected $firstPageWritten = false; protected $lastPageWritten = false; protected $checkpointJustWritten = false; + /** @var string[] */ protected $checkpointFiles = []; /** @@ -302,6 +304,7 @@ TEXT $param = $split[1]; } $fileURIs = explode( ';', $param ); + $newFileURIs = []; foreach ( $fileURIs as $URI ) { switch ( $val ) { case "file": @@ -431,7 +434,7 @@ TEXT /** * @throws MWException Failure to parse XML input - * @param string $input + * @param resource $input * @return bool */ function readDump( $input ) { @@ -808,11 +811,11 @@ TEXT if ( $this->spawnRead ) { fclose( $this->spawnRead ); } - $this->spawnRead = false; + $this->spawnRead = null; if ( $this->spawnWrite ) { fclose( $this->spawnWrite ); } - $this->spawnWrite = false; + $this->spawnWrite = null; if ( $this->spawnErr ) { fclose( $this->spawnErr ); }