com php-src: use MSG_PEEK flag for recv() everywh ere: phpdbg_io.c

From: Date: Sun, 19 Oct 2014 09:03:17 +0000
Subject: com php-src: use MSG_PEEK flag for recv() everywh ere: phpdbg_io.c
Groups: php.cvs 
Request: Send a blank email to php-cvs+get-82543@lists.php.net to get a copy of this message
Commit: 52686b322682e470c9664cfb01d69406b44b7b20 Author: Anatol Belski <ab@php.net> Sun, 19 Oct 2014 11:03:17 +0200 Parents: e853fec3fd63b3c511faba3a841911715cd340c8 Branches: PHP-5.6 Link: http://git.php.net/?p=php-src.git;a=commitdiff;h=52686b322682e470c9664cfb01d69406b44b7b20 Log: use MSG_PEEK flag for recv() everywhere Changed paths: M phpdbg_io.c Diff: diff --git a/phpdbg_io..c b/phpdbg_io.c index f358fbf..6de1397 100644 --- a/phpdbg_io.c +++ b/phpdbg_io.c @@ -83,11 +83,11 @@ phpdbg_consume_bytes(int sock, char *ptr, int len, int tmo) } while(i > 0) { -#ifdef PHP_WIN32 + /* There's something to read. Read what's available and proceed + disregarding whether len could be exhausted or not.*/ int can_read = recv(sock, p, i, MSG_PEEK); - i = can_read; -#endif + got_now = recv(sock, p, i, 0); if (got_now == -1) { return -1;

« previous php.cvs (#82543) next »