codeminders / php-amqplib

PHP library implementing Advanced Message Queuing Protocol (AMQP).
GNU Lesser General Public License v2.1
0 stars 0 forks source link

Large packets result in error and unexpected connection loss #11

Open GoogleCodeExporter opened 9 years ago

GoogleCodeExporter commented 9 years ago
amqp.inc at around ln 390

if(false == ($written = fwrite($this->sock, $data)))

should be

if(false === ($written = fwrite($this->sock, $data)))

If you're sending a large packet, fwrite may sit around (not sending data),
waiting for room to appear in the buffer. In the mean time, fwrite is
returning 0, even though there isn't an error.

(return value should be strictly false if there is an error, not 0)

Original issue reported on code.google.com by sonics...@gmail.com on 12 Dec 2009 at 4:01

GoogleCodeExporter commented 9 years ago
Observed this when run within Windows XP instance under VirtualBox -> errno 
10054 
(WSAECONNRESET)

Original comment by sigurd.h...@gtempaccount.com on 5 Feb 2010 at 5:12

GoogleCodeExporter commented 9 years ago
[deleted comment]
GoogleCodeExporter commented 9 years ago
Lyolik please review these bugs.

Original comment by kroko...@gmail.com on 21 Mar 2010 at 9:17