pub fn read_cstring(buffer: &[u8], offset: usize) -> Result<&str, &'static str>Expand description
Helper to read a null-terminated UTF-8 string from buffer
Returns error if offset is out of bounds, string is not null-terminated, or bytes are not valid UTF-8.