This sounds like reasonable behavior to me. Keep in mind that your data, [99u8, 99u8] has type [u8, ..2] and size size of 2 bytes, not the 512 you're expecing.
On Mon, Sep 16, 2013 at 11:06:51PM +0200, Maik Klein wrote: > [1]https://gist.github.com/MaikKlein/6586333 > Basically what happens is that a packet is read "partially" if the > buffer is to small for the packet. According to > [2]http://gafferongames.com/networking-for-game-programmers/sending-and > -receiving-packets/ this should not happen. > In my case I send [99u8,99u8] which should be of size 512 and my buffer > is [0u8,..1] which should be of size 256. But it still receives the > first 99. > > References > > 1. https://gist.github.com/MaikKlein/6586333 > 2. > http://gafferongames.com/networking-for-game-programmers/sending-and-receiving-packets/ > _______________________________________________ > Rust-dev mailing list > [email protected] > https://mail.mozilla.org/listinfo/rust-dev _______________________________________________ Rust-dev mailing list [email protected] https://mail.mozilla.org/listinfo/rust-dev
