From 7d2ef0ee95c59cdceaa7c4dc0bd0c0d41e9938c1 Mon Sep 17 00:00:00 2001 From: Ivan Borzenkov Date: Mon, 8 Mar 2010 00:49:54 +0300 Subject: [PATCH] remove stream non-blocking - any micro timeout break connection --- XMPPHP/XMLStream.php | 8 -------- 1 file changed, 8 deletions(-) diff --git a/XMPPHP/XMLStream.php b/XMPPHP/XMLStream.php index cd03c96..0ffec4d 100644 --- a/XMPPHP/XMLStream.php +++ b/XMPPHP/XMLStream.php @@ -457,15 +457,7 @@ class XMPPHP_XMLStream { } else if ($updated > 0) { $buff = ''; do { - if ($buff != '') { - //disable blocking for now because fread() will - // block until the 4k are full if we already - // read a part of the packet - stream_set_blocking($this->socket, 0); - } $part = fread($this->socket, 4096); - stream_set_blocking($this->socket, 1); - if (!$part) { if($this->reconnect) { $this->doReconnect();