Skip to main content

field_line

Function field_line 

Source
pub fn field_line(buf: &[u8]) -> (usize, usize, usize)
Expand description

Offsets of one header field line at the start of buf, found in a single dispatch: (name_end, value_start, value_end). name_end is the length of the TCHAR run. If the byte there is :, value_start is past the colon and any SP/HTAB, and value_end ends the FIELD_VALUE run from there (trailing whitespace included); otherwise both equal name_end. The caller checks the bytes at name_end and value_end.