[−][src]Function bincode::internal::deserialize_from
pub fn deserialize_from<R, T, S, E>(reader: R, size_limit: S) -> Result<T> where
R: Read,
T: DeserializeOwned,
S: SizeLimit,
E: ByteOrder,
Deserializes an object directly from a Read
er.
If the provided SizeLimit
is reached, the deserialization will bail immediately.
A SizeLimit can help prevent an attacker from flooding your server with
a neverending stream of values that runs your server out of memory.
If this returns an Error
, assume that the buffer that you passed
in is in an invalid state, as the error could be returned during any point
in the reading.