X-Git-Url: https://git.heureux-cyclage.org/?p=lhc%2Fweb%2Fwiklou.git;a=blobdiff_plain;f=includes%2Ffilerepo%2FFileRepo.php;h=0c37d78b2627ef76b1131da6324849ac4290d990;hp=e430bc8f43b28ff9e334a3709c072b373fe9b95a;hb=30d72ec3d0914bb905d4114dee9256f02cbdcc7f;hpb=7f11daf961e97a78c7893fcf91c614bb777e3559;ds=sidebyside diff --git a/includes/filerepo/FileRepo.php b/includes/filerepo/FileRepo.php index e430bc8f43..0c37d78b26 100644 --- a/includes/filerepo/FileRepo.php +++ b/includes/filerepo/FileRepo.php @@ -1634,7 +1634,11 @@ class FileRepo { $status = $this->newGood(); $status->merge( $this->backend->streamFile( $params ) ); - ob_end_flush(); + // T186565: Close the buffer, unless it has already been closed + // in HTTPFileStreamer::resetOutputBuffers(). + if ( ob_get_status() ) { + ob_end_flush(); + } return $status; }