pub fn decode_reply(bytes: &[u8], expected_id: u32) -> Result<Reply>
Counts and strings are validated before allocating collections or copying data.