Bug 1317946: allow receiving zero size UDP messages. r?schien
MozReview-Commit-ID: B8B1yDOPi3h
--- a/netwerk/base/nsUDPSocket.cpp
+++ b/netwerk/base/nsUDPSocket.cpp
@@ -467,22 +467,16 @@ nsUDPSocket::OnSocketReady(PRFileDesc *f
}
PRNetAddr prClientAddr;
uint32_t count;
// Bug 1252755 - use 9216 bytes to allign with nICEr and transportlayer to
// support the maximum size of jumbo frames
char buff[9216];
count = PR_RecvFrom(mFD, buff, sizeof(buff), 0, &prClientAddr, PR_INTERVAL_NO_WAIT);
-
- if (count < 1) {
- NS_WARNING("error of recvfrom on UDP socket");
- mCondition = NS_ERROR_UNEXPECTED;
- return;
- }
mByteReadCount += count;
FallibleTArray<uint8_t> data;
if (!data.AppendElements(buff, count, fallible)) {
mCondition = NS_ERROR_UNEXPECTED;
return;
}