mirror of
https://github.com/hrydgard/ppsspp.git
synced 2025-04-02 11:01:50 -04:00
http: Avoid logging errors for would block.
It's not an error, this case is expected.
This commit is contained in:
parent
a8059d53f9
commit
c98d96c78f
1 changed files with 9 additions and 0 deletions
|
@ -21,6 +21,7 @@
|
||||||
#endif
|
#endif
|
||||||
|
|
||||||
#include <algorithm>
|
#include <algorithm>
|
||||||
|
#include <cerrno>
|
||||||
#include <cstdarg>
|
#include <cstdarg>
|
||||||
|
|
||||||
#include "net/sinks.h"
|
#include "net/sinks.h"
|
||||||
|
@ -185,6 +186,14 @@ bool InputSink::Block() {
|
||||||
|
|
||||||
void InputSink::AccountFill(int bytes) {
|
void InputSink::AccountFill(int bytes) {
|
||||||
if (bytes < 0) {
|
if (bytes < 0) {
|
||||||
|
#if PPSSPP_PLATFORM(WINDOWS)
|
||||||
|
int err = WSAGetLastError();
|
||||||
|
if (err == WSAEWOULDBLOCK)
|
||||||
|
return;
|
||||||
|
#else
|
||||||
|
if (errno == EWOULDBLOCK || errno == EAGAIN)
|
||||||
|
return;
|
||||||
|
#endif
|
||||||
ERROR_LOG(IO, "Error reading from socket");
|
ERROR_LOG(IO, "Error reading from socket");
|
||||||
return;
|
return;
|
||||||
}
|
}
|
||||||
|
|
Loading…
Add table
Reference in a new issue