mirror of
https://github.com/Noratrieb/dilaria.git
synced 2026-01-14 17:35:03 +01:00
fix stackoverflow
This commit is contained in:
parent
141e8e09bf
commit
8952e8082a
4 changed files with 201 additions and 37 deletions
|
|
@ -1,6 +1,11 @@
|
|||
#![no_main]
|
||||
use libfuzzer_sys::fuzz_target;
|
||||
|
||||
fuzz_target!(|data: &[u8]| {
|
||||
// fuzzed code goes here
|
||||
fuzz_target!(|data: String| {
|
||||
let lexer = script_lang::Lexer::lex(&data);
|
||||
let tokens = lexer.collect::<Result<Vec<_>, _>>();
|
||||
|
||||
if let Ok(tokens) = tokens {
|
||||
let _ast = script_lang::parse(tokens);
|
||||
}
|
||||
});
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue