wininet: Don't try to read anything if 0 bytes are to be read.
Robert Shearman
rob at codeweavers.com
Wed Jan 10 09:30:22 CST 2007
---
dlls/wininet/netconnection.c | 5 +++++
1 files changed, 5 insertions(+), 0 deletions(-)
-------------- next part --------------
diff --git a/dlls/wininet/netconnection.c b/dlls/wininet/netconnection.c
index 8a4c72b..2418b97 100644
--- a/dlls/wininet/netconnection.c
+++ b/dlls/wininet/netconnection.c
@@ -498,6 +498,11 @@ BOOL NETCON_recv(WININET_NETCONNECTION *
int *recvd /* out */)
{
if (!NETCON_connected(connection)) return FALSE;
+ if (!len)
+ {
+ *recvd = 0;
+ return TRUE;
+ }
if (!connection->useSSL)
{
*recvd = recv(connection->socketFD, buf, len, flags);
More information about the wine-patches
mailing list