mirror of https://github.com/PCSX2/pcsx2.git
DEV9: Tap, make GetOverlappedResult calls one line
This commit is contained in:
parent
54651731f9
commit
b097ca9979
|
@ -308,12 +308,10 @@ bool TAPAdapter::recv(NetPacket* pkt)
|
||||||
{
|
{
|
||||||
CancelIo(htap);
|
CancelIo(htap);
|
||||||
//Wait for the I/O subsystem to acknowledge our cancellation
|
//Wait for the I/O subsystem to acknowledge our cancellation
|
||||||
result = GetOverlappedResult(htap, &read,
|
result = GetOverlappedResult(htap, &read, &read_size, TRUE);
|
||||||
&read_size, TRUE);
|
|
||||||
}
|
}
|
||||||
else
|
else
|
||||||
result = GetOverlappedResult(htap, &read,
|
result = GetOverlappedResult(htap, &read, &read_size, FALSE);
|
||||||
&read_size, FALSE);
|
|
||||||
|
|
||||||
if (!result)
|
if (!result)
|
||||||
{
|
{
|
||||||
|
@ -360,8 +358,8 @@ bool TAPAdapter::send(NetPacket* pkt)
|
||||||
if (dwError == ERROR_IO_PENDING)
|
if (dwError == ERROR_IO_PENDING)
|
||||||
{
|
{
|
||||||
WaitForSingleObject(write.hEvent, INFINITE);
|
WaitForSingleObject(write.hEvent, INFINITE);
|
||||||
result = GetOverlappedResult(htap, &write,
|
result = GetOverlappedResult(htap, &write, &writen, FALSE);
|
||||||
&writen, FALSE);
|
|
||||||
if (!result)
|
if (!result)
|
||||||
{
|
{
|
||||||
}
|
}
|
||||||
|
|
Loading…
Reference in New Issue