sas Fri Oct 4 15:36:10 2002 EDT Modified files: /php4/main streams.c Log: Interrupt loop, if the stream op fails. Index: php4/main/streams.c diff -u php4/main/streams.c:1.93 php4/main/streams.c:1.94 --- php4/main/streams.c:1.93 Fri Oct 4 15:08:43 2002 +++ php4/main/streams.c Fri Oct 4 15:36:09 2002 @@ -20,7 +20,7 @@ +----------------------------------------------------------------------+ */ -/* $Id: streams.c,v 1.93 2002/10/04 19:08:43 sas Exp $ */ +/* $Id: streams.c,v 1.94 2002/10/04 19:36:09 sas Exp $ */ #define _GNU_SOURCE #include "php.h" @@ -713,8 +713,11 @@ if (toread > stream->chunk_size) toread = stream->chunk_size; - /* XXX: Should not the loop end, if the stream op fails? */ php_stream_fill_read_buffer(stream, toread TSRMLS_CC); + + if (stream->writepos - stream->readpos == 0) { + break; + } } }
-- PHP CVS Mailing List (http://www.php.net/) To unsubscribe, visit: http://www.php.net/unsub.php