Bug 1165423 - WebRTC Fix DTLS handshake by expanding UDP buffer. r=rjesup
authorEthan Hugg <ethanhugg@gmail.com>
Fri, 15 May 2015 16:58:56 -0700
changeset 244301 6dd7de1d30276c2e37c57190e6d248237aff6c3b
parent 244300 2d331d4ba0f5e18dcd31fa984178ff8d547cdce7
child 244302 b769ef24faed7e6388589133c5f039c4be248e23
push id59893
push usercbook@mozilla.com
push dateMon, 18 May 2015 07:08:54 +0000
treeherdermozilla-inbound@6dd7de1d3027 [default view] [failures only]
perfherder[talos] [build metrics] [platform microbench] (compared to previous push)
reviewersrjesup
bugs1165423
milestone41.0a1
first release with
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
last release without
nightly linux32
nightly linux64
nightly mac
nightly win32
nightly win64
Bug 1165423 - WebRTC Fix DTLS handshake by expanding UDP buffer. r=rjesup
netwerk/base/nsUDPSocket.cpp
--- a/netwerk/base/nsUDPSocket.cpp
+++ b/netwerk/base/nsUDPSocket.cpp
@@ -655,17 +655,19 @@ nsUDPSocket::OnSocketReady(PRFileDesc *f
   {
     NS_WARNING("error polling on listening socket");
     mCondition = NS_ERROR_UNEXPECTED;
     return;
   }
 
   PRNetAddr prClientAddr;
   uint32_t count;
-  char buff[1500];
+  // Bug 1165423 - using 8k here because the packet could be larger
+  // than the MTU with fragmentation
+  char buff[8 * 1024];
   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;