You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
encryptBuffer.writeDirect(0, sizeof(UdpPacketHeader), header); // Only really need length updating
577
-
assert(length <= DATA_PAYLOAD);
575
+
UdpPacketHeader newHeader;
576
+
newHeader.length = encryptBuffer.length();
577
+
encryptBuffer.writeDirect(offsetof(UdpPacketHeader, length), sizeof(newHeader.length), &newHeader.length); // Only need to update the length - rest is the same
578
+
assertex(encryptBuffer.length() <= DATA_PAYLOAD);
578
579
if (udpTraceLevel > 5)
579
580
DBGLOG("ENCRYPT: Writing %u bytes to data socket", encryptBuffer.length());
0 commit comments