skipping non-executable files

This commit is contained in:
Mike Aizatsky 2016-10-10 09:23:21 -07:00 committed by GitHub
parent 21b61ebe6c
commit 17a65504da
1 changed files with 5 additions and 3 deletions

View File

@ -84,6 +84,7 @@ def call(body) {
} }
} }
// Run each of resulting fuzzers.
dir ('out') { dir ('out') {
stage name: "Running fuzzers" stage name: "Running fuzzers"
sh "ls -alR" sh "ls -alR"
@ -94,10 +95,11 @@ def call(body) {
def files = findFiles() def files = findFiles()
for (int j = 0; j < files.size(); j++) { for (int j = 0; j < files.size(); j++) {
def file = files[j] def file = files[j]
if (file.name.endsWith('.dict') || file.name.endsWith('.options') || file.directory) { if (file.directory) { continue }
if (!new File(file.name).canExecute()) {
echo "skipping: $file"
continue continue
} }
echo "FILE: $file"
sh "docker run -v $d:/out -t ossfuzz/libfuzzer-runner /out/$file -runs=1" sh "docker run -v $d:/out -t ossfuzz/libfuzzer-runner /out/$file -runs=1"
} }
} }