From e1599a19c059f227631295c7cfcef6a0320873e9 Mon Sep 17 00:00:00 2001 From: Ralf Becker Date: Sat, 10 Jul 2004 08:01:25 +0000 Subject: [PATCH] fix for big files in web_dav as suggested by bug [ 964418 ] Downloading large files through webdav fails --- phpgwapi/inc/class.net_http_client.inc.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/phpgwapi/inc/class.net_http_client.inc.php b/phpgwapi/inc/class.net_http_client.inc.php index 572f11a3c4..c8e8a3df96 100644 --- a/phpgwapi/inc/class.net_http_client.inc.php +++ b/phpgwapi/inc/class.net_http_client.inc.php @@ -786,7 +786,9 @@ class net_http_client else if ($this->responseHeaders['Content-Length'] ) { $length = $this->responseHeaders['Content-Length']; - $data = fread( $this->socket, $length ); + while (!feof($this->socket)) { + $data .= fread($this->socket, 1024); + } if( $this->debug & DBGSOCK ) echo "DBG.SOCK socket_read using Content-Length ($length)\n"; }