aboutsummaryrefslogtreecommitdiffstats
path: root/askama_parser/fuzz
diff options
context:
space:
mode:
authorLibravatar manunio <max.manu.nair@gmail.com>2023-09-18 18:38:48 +0530
committerLibravatar Dirkjan Ochtman <dirkjan@ochtman.nl>2023-09-18 15:57:17 +0200
commit2ef2b9db9e7dfdb57e6c8b59db5493864aaacf3a (patch)
treec807af88cc93689240d8eb182191ea3ab71c4446 /askama_parser/fuzz
parent8f3140a33fa76be248883539d8ecb51b7a7700e2 (diff)
downloadaskama-2ef2b9db9e7dfdb57e6c8b59db5493864aaacf3a.tar.gz
askama-2ef2b9db9e7dfdb57e6c8b59db5493864aaacf3a.tar.bz2
askama-2ef2b9db9e7dfdb57e6c8b59db5493864aaacf3a.zip
fuzz: remove input limit
While working on https://github.com/djc/askama/pull/862 fuzz_parser was crashing and failing oss-fuzz build_checks. so a limit of 500 was placed, this pr removes that.
Diffstat (limited to 'askama_parser/fuzz')
-rw-r--r--askama_parser/fuzz/fuzz_targets/fuzz_parser.rs6
1 files changed, 2 insertions, 4 deletions
diff --git a/askama_parser/fuzz/fuzz_targets/fuzz_parser.rs b/askama_parser/fuzz/fuzz_targets/fuzz_parser.rs
index 374936c..1be1f94 100644
--- a/askama_parser/fuzz/fuzz_targets/fuzz_parser.rs
+++ b/askama_parser/fuzz/fuzz_targets/fuzz_parser.rs
@@ -5,9 +5,7 @@ use std::str;
fuzz_target!(|data: &[u8]| {
// fuzzed code goes here
- if data.len() < 500 {
- if let Ok(data) = str::from_utf8(data) {
- if let Ok(_) = Ast::from_str(data, &Syntax::default()) {}
- }
+ if let Ok(data) = str::from_utf8(data) {
+ if let Ok(_) = Ast::from_str(data, &Syntax::default()) {}
}
});