mirror of
https://gitlab.com/veloren/veloren.git
synced 2024-08-30 18:12:32 +00:00
Merge branch 'zesterer/net-fixes' into 'master'
Network fix for 32-bit See merge request veloren/veloren!238
This commit is contained in:
commit
121d9e0d61
@ -204,7 +204,8 @@ impl<S: PostMsg, R: PostMsg> PostBox<S, R> {
|
||||
*/
|
||||
|
||||
// Assemble into packet.
|
||||
let mut packet_bytes = msg_bytes.len().to_le_bytes().as_ref().to_vec();
|
||||
let mut packet_bytes =
|
||||
(msg_bytes.len() as u64).to_le_bytes().as_ref().to_vec();
|
||||
packet_bytes.push(msg_bytes.iter().fold(0, |a, x| a ^ *x));
|
||||
packet_bytes.append(&mut msg_bytes);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user