pub async fn read_message<R, T>(r: &mut R) -> Result<T, DaemonError>Expand description
Read one length-prefixed JSON message from r.
§Errors
Returns DaemonError::Io on a transport failure (including a
clean EOF before any bytes arrive) or DaemonError::Protocol if
the declared length exceeds MAX_MESSAGE_BYTES or the body fails
to deserialize.