From: Tim Düsterhus Date: Thu, 21 Jan 2021 08:33:22 +0000 (+0100) Subject: Set 'stream' to `true` for Guzzle in `HTTPRequest` X-Git-Tag: 5.3.3~17 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=5fc80baf9a348a63baaaa6fa150b1732adfc9f3c;p=GitHub%2FWoltLab%2FWCF.git Set 'stream' to `true` for Guzzle in `HTTPRequest` This is required to properly support the 'maxLength' option on endless streams (such as a web radio). Without setting 'stream' to `true`, Guzzle attempts to download the entire response body before returning from `->send()`. --- diff --git a/wcfsetup/install/files/lib/util/HTTPRequest.class.php b/wcfsetup/install/files/lib/util/HTTPRequest.class.php index 2867920d99..11aa2c611e 100644 --- a/wcfsetup/install/files/lib/util/HTTPRequest.class.php +++ b/wcfsetup/install/files/lib/util/HTTPRequest.class.php @@ -173,6 +173,7 @@ final class HTTPRequest { 'track_redirects' => true, 'on_redirect' => $redirectHandler, ], + 'stream' => true, ]; if (isset($this->options['auth'])) { $options['auth'] = [