From 33fc0ae3967f3635db7bde7e2aab934b1256b88f Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=90=91=E6=9E=97?= Date: Fri, 24 Dec 2021 14:38:26 +0800 Subject: [PATCH] =?UTF-8?q?=E6=94=B9=E5=90=8D?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/AsyncClient.php | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/src/AsyncClient.php b/src/AsyncClient.php index 0f1350d..398bd68 100644 --- a/src/AsyncClient.php +++ b/src/AsyncClient.php @@ -84,7 +84,7 @@ class AsyncClient extends ClientAbstracts if ($isHttps || $this->isSSL()) { $this->client->enableSSL(); } - $this->client->set(array_merge($this->settings(), ['package_eof' => "\r\n\r\n", 'open_eof_check' => true])); + $this->client->set(array_merge($this->settings(), ['open_http_protocol' => true])); if (!empty($this->getAgent())) { $this->withAddedHeader('User-Agent', $this->getAgent()); } @@ -107,7 +107,7 @@ class AsyncClient extends ClientAbstracts private function execute(string $path, string $content) { $array = []; - $array[] = strtoupper($this->getMethod()) . ' ' . $path . ' HTTP/1.0'; + $array[] = strtoupper($this->getMethod()) . ' ' . $path . ' HTTP/1.1'; if (!empty($this->getHeader())) { foreach ($this->getHeader() as $key => $value) { $array[] = sprintf('%s: %s', $key, $value);