MCPcopy Create free account
hub / github.com/MultiFuzz/MultiFuzz / parse_modification

Function parse_modification

hail-fuzz/src/debugging/mod.rs:139–149  ·  view source on GitHub ↗

Parses an insertion/replacement expression of the form: " , , " e.g. 0x40000418,0,0a0b0c0d

(insert: &str)

Source from the content-addressed store, hash-verified

137///
138/// e.g. 0x40000418,0,0a0b0c0d
139fn parse_modification(insert: &str) -> Option<(u64, usize, Vec<u8>)> {
140 use icicle_fuzzing::parse_u64_with_prefix;
141 use icicle_vm::cpu::utils::bytes_from_hex;
142
143 let mut parts = insert.split(',');
144 let stream = parse_u64_with_prefix(parts.next()?)?;
145 let offset = parse_u64_with_prefix(parts.next()?)?;
146 let bytes = bytes_from_hex(parts.next()?)?;
147
148 Some((stream, offset as usize, bytes))
149}

Callers 1

modify_inputFunction · 0.85

Calls

no outgoing calls

Tested by

no test coverage detected