#[non_exhaustive]
#[derive(Debug, thiserror::Error, Clone, PartialEq, Eq)]
pub enum RtmpError {
#[error(transparent)]
BufferTooShort(#[from] broadcast_common::error::BufferTooShort),
#[error("malformed {what}")]
Malformed {
what: &'static str,
},
#[error("unexpected state: {what}")]
UnexpectedState {
what: &'static str,
},
#[error("unsupported: {what}")]
Unsupported {
what: &'static str,
},
#[error("chunk stream id {chunk_stream_id} is outside the encodable range 2..=65599")]
InvalidChunkStreamId {
chunk_stream_id: u32,
},
#[error(transparent)]
FieldOverflow(#[from] broadcast_common::error::FieldOverflow),
#[error(transparent)]
OutputBufferTooSmall(#[from] broadcast_common::error::OutputBufferTooSmall),
}