Skip to main content

sginstrument/
lib.rs

1unsafe extern "C" {
2    fn __sfuzzer_instrument(location: std::os::raw::c_uint, state_value: std::os::raw::c_uint);
3}
4
5/// Informs the fuzzer that a new state has been reached.
6pub fn instrument(location: u32, state_value: u32) {
7    unsafe {
8        __sfuzzer_instrument(location, state_value);
9    }
10}
11
12#[cfg(test)]
13mod test {
14    use crate::instrument;
15
16    #[test]
17    fn test() {
18        instrument(0, 0);
19    }
20}