From b171cc6c59f377d28cd2afca76cb0d67162c7787 Mon Sep 17 00:00:00 2001 From: Sergey Poznyakoff Date: Tue, 31 Aug 2021 16:36:35 +0300 Subject: Add seed builder script and runcom file for gdbm_fuzzer --- fuzz/build_seed.sh | 109 ++++++++++++++++++++++++++++++++++++++++++++++++++++ fuzz/gdbm_fuzzer.rc | 31 +++++++++++++++ 2 files changed, 140 insertions(+) create mode 100644 fuzz/build_seed.sh create mode 100644 fuzz/gdbm_fuzzer.rc diff --git a/fuzz/build_seed.sh b/fuzz/build_seed.sh new file mode 100644 index 0000000..5e92924 --- /dev/null +++ b/fuzz/build_seed.sh @@ -0,0 +1,109 @@ +#!/bin/sh +# This file is part of GDBM. +# Copyright (C) 2021 Free Software Foundation, Inc. +# +# GDBM is free software; you can redistribute it and/or modify +# it under the terms of the GNU General Public License as published by +# the Free Software Foundation; either version 3, or (at your option) +# any later version. +# +# GDBM is distributed in the hope that it will be useful, +# but WITHOUT ANY WARRANTY; without even the implied warranty of +# MERCHANTABILITY or FITNESS FOR A PARTICULAR PURPOSE. See the +# GNU General Public License for more details. +# +# You should have received a copy of the GNU General Public License +# along with GDBM. If not, see . */ + +set -e + +unset wd +while getopts "C:" OPTION +do + case $OPTION in + C) wd=$OPTARG;; + esac +done + +if [ -n "$wd" ]; then + if [ ! -d $wd ]; then + mkdir $wd + fi + cd $wd +fi + +for format in standard numsync; do + gdbmtool < +# This is free software: you are free to change and redistribute it. +# There is NO WARRANTY, to the extent permitted by law. +set errorexit +open +set noerrorexit +set errormask +avail +cache +count +dir +header +current +first +next +status +set coalesce +set centfree +recover +reorganize +fetch 1 +delete 1 +store 1 1 +delete 1 +bucket 1 +upgrade +downgrade +close +quit -- cgit v1.2.1