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
pub fn colliders(&mut self) -> Result<Vec<BoxDimensions>, Box<dyn std::error::Error>> {
let tcp = Self::tcp()?;
let mut reader = BufReader::new(&tcp);
let mut writer = BufWriter::new(&tcp);
writer.write(&[PacketType::FetchCollidersPacket as u8])?;
writer.write_all(&serialize(FetchColliders::new())?)?;
writer.flush();
let vec: Vec<BoxDimensions> = deserialize(reader)?;
Ok(vec.clone())
}
On both 1.0, and 2.0, I get an "unexpected eof" error, even though I confirmed that after flushing the writer, I can in fact read the struct with reader.read_to_end; I even tried just saving the result of that function to a vec and then passing it to bincode::decode_from_slice , but I get the same error.
The text was updated successfully, but these errors were encountered:
struct:
deserialization function:
function that calls it:
On both 1.0, and 2.0, I get an "unexpected eof" error, even though I confirmed that after flushing the writer, I can in fact read the struct with
reader.read_to_end
; I even tried just saving the result of that function to a vec and then passing it tobincode::decode_from_slice
, but I get the same error.The text was updated successfully, but these errors were encountered: