com php-src: fix pipe peek timeout: main/streams/plain_wrappe r.c
| From: | Anatol Belski | Date: | Thu, 02 Jul 2015 13:19:38 +0000 |
| Subject: | com php-src: fix pipe peek timeout: main/streams/plain_wrappe r.c | ||
| Groups: | php.cvs | ||
| Request: | Send a blank email to php-cvs+get-87689@lists.php.net to get a copy of this message | ||
Commit: 6f3dd4d45b022504bf334add7934536289ce381c
Author: Anatol Belski <ab@php.net> Thu, 2 Jul 2015 15:19:38 +0200
Parents: 58b982afed4f4a5c00190e81b229375bceabe8ab
Branches: master
Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=6f3dd4d45b022504bf334add7934536289ce381c
Log:
fix pipe peek timeout
Changed paths:
M main/streams/plain_wrapper.c
Diff:
diff --git a/main/streams/plain_wrapper.c b/main/streams/plain_wrapper.c
index 8122a76..101fe4a 100644
--- a/main/streams/plain_wrapper.c
+++ b/main/streams/plain_wrapper..c
@@ -378,11 +378,11 @@ static size_t php_stdiop_read(php_stream *stream, char *buf, size_t count)
if (!PeekNamedPipe(ph, NULL, 0, NULL, &avail_read, NULL)) {
break;
}
- /* If there's nothing to read, wait in 100ms periods. */
+ /* If there's nothing to read, wait in 10ms periods. */
if (0 == avail_read) {
- usleep(100000);
+ usleep(10);
}
- } while (0 == avail_read && retry++ < 320);
+ } while (0 == avail_read && retry++ < 3200000);
/* Reduce the required data amount to what is available, otherwise read()
will block.*/