[][src]Enum etherparse::TcpOptionReadError

pub enum TcpOptionReadError {
    UnexpectedEndOfSlice(u8),
    UnexpectedSize {
        option_id: u8,
        size: u8,
    },
    UnknownId(u8),
}

Errors that can occour while reading the options of a TCP header.

Variants

UnexpectedEndOfSlice(u8)

Returned if an option id was read, but there was not enough memory in the options left to completely read it.

UnexpectedSize

Returned if the option as an unexpected size argument (e.g. != 4 for maximum segment size).

Fields of UnexpectedSize

option_id: u8size: u8
UnknownId(u8)

Returned if an unknown tcp header option is encountered.

The first element is the identifier and the slice contains the rest of data left in the options.

Trait Implementations

impl Clone for TcpOptionReadError[src]

impl Eq for TcpOptionReadError[src]

impl PartialEq<TcpOptionReadError> for TcpOptionReadError[src]

impl Debug for TcpOptionReadError[src]

impl StructuralPartialEq for TcpOptionReadError[src]

impl StructuralEq for TcpOptionReadError[src]

Auto Trait Implementations

Blanket Implementations

impl<T, U> Into<U> for T where
    U: From<T>, 
[src]

impl<T> From<T> for T[src]

impl<T> ToOwned for T where
    T: Clone
[src]

type Owned = T

The resulting type after obtaining ownership.

impl<T, U> TryFrom<U> for T where
    U: Into<T>, 
[src]

type Error = Infallible

The type returned in the event of a conversion error.

impl<T, U> TryInto<U> for T where
    U: TryFrom<T>, 
[src]

type Error = <U as TryFrom<T>>::Error

The type returned in the event of a conversion error.

impl<T> Borrow<T> for T where
    T: ?Sized
[src]

impl<T> BorrowMut<T> for T where
    T: ?Sized
[src]

impl<T> Any for T where
    T: 'static + ?Sized
[src]