Author: cgutman
Date: Thu Jul 7 11:40:25 2011
New Revision: 52553
URL:
http://svn.reactos.org/svn/reactos?rev=52553&view=rev
Log:
[MSAFD]
- Let WSPRecv handle WSPRecvFrom on a non-datagram socket (mswsock_new does this)
- Fixes recvfrom on connection-oriented sockets
Modified:
trunk/reactos/dll/win32/msafd/misc/sndrcv.c
Modified: trunk/reactos/dll/win32/msafd/misc/sndrcv.c
URL:
http://svn.reactos.org/svn/reactos/trunk/reactos/dll/win32/msafd/misc/sndrc…
==============================================================================
--- trunk/reactos/dll/win32/msafd/misc/sndrcv.c [iso-8859-1] (original)
+++ trunk/reactos/dll/win32/msafd/misc/sndrcv.c [iso-8859-1] Thu Jul 7 11:40:25 2011
@@ -279,6 +279,20 @@
{
*lpErrno = WSAENOTSOCK;
return SOCKET_ERROR;
+ }
+
+ if (!(Socket->SharedData.ServiceFlags1 & XP1_CONNECTIONLESS))
+ {
+ /* Call WSPRecv for a non-datagram socket */
+ return WSPRecv(Handle,
+ lpBuffers,
+ dwBufferCount,
+ lpNumberOfBytesRead,
+ ReceiveFlags,
+ lpOverlapped,
+ lpCompletionRoutine,
+ lpThreadId,
+ lpErrno);
}
Status = NtCreateEvent( &SockEvent, GENERIC_READ | GENERIC_WRITE,