//! Fuzzes RTSP requests. //! Asserts invariants, not only "no panic": parse -> encode -> parse is stable. //! How to run: see the comment at the top of `fuzz/Cargo.toml`. #![no_main] use libfuzzer_sys::fuzz_target; fuzz_target!(|data: &[u8]| { if let Ok(req) = domistream::rtsp::parse_request(data) { let bytes = req.encode().expect("a parsed request encodes"); assert_eq!(domistream::rtsp::parse_request(&bytes), Ok(req)); } });