diff options
author | Caolán McNamara <caolanm@redhat.com> | 2018-02-12 15:20:03 +0000 |
---|---|---|
committer | Caolán McNamara <caolanm@redhat.com> | 2018-02-12 21:36:14 +0100 |
commit | 76c58b1cfbe2ab41b8e33d40953341410be7db96 (patch) | |
tree | 5db5e56d2ca2835a36962ddb34822dadb3a2b282 /vcl/workben | |
parent | 4c925efc4373a5a09941b56d2edd30500987dd25 (diff) |
for ~perfect compression link fuzzer input limit to an output limit
Change-Id: I30c3a0b75c818b55f6e73fdb68bf59fdac249d0e
Reviewed-on: https://gerrit.libreoffice.org/49606
Tested-by: Jenkins <ci@libreoffice.org>
Reviewed-by: Caolán McNamara <caolanm@redhat.com>
Tested-by: Caolán McNamara <caolanm@redhat.com>
Diffstat (limited to 'vcl/workben')
-rw-r--r-- | vcl/workben/commonfuzzer.hxx | 9 |
1 files changed, 9 insertions, 0 deletions
diff --git a/vcl/workben/commonfuzzer.hxx b/vcl/workben/commonfuzzer.hxx index 9b6f5728572c..cc4830fa5990 100644 --- a/vcl/workben/commonfuzzer.hxx +++ b/vcl/workben/commonfuzzer.hxx @@ -87,6 +87,15 @@ void CommonInitialize(int *argc, char ***argv) setenv("SAL_DISABLE_DEFAULTPRINTER", "1", 1); setenv("SAL_NO_FONT_LOOKUP", "1", 1); + //allow bubbling of max input len to fuzzer targets + int nMaxLen = 0; + for (int i = 0; i < *argc; ++i) + { + if (strncmp((*argv)[i], "-max_len=", 9) == 0) + nMaxLen = atoi((*argv)[i] + 9); + } + setenv("FUZZ_MAX_INPUT_LEN", "1", nMaxLen); + osl_setCommandArgs(*argc, *argv); OUString sExecDir = getExecutableDir(); |