mirror of
https://github.com/isc-projects/bind9.git
synced 2026-02-26 03:11:56 -05:00
16 lines
353 B
Bash
Executable file
16 lines
353 B
Bash
Executable file
#!/bin/sh
|
|
|
|
ret=0
|
|
for spatch in cocci/*.spatch; do
|
|
patch="$(dirname "$spatch")/$(basename "$spatch" .spatch).patch"
|
|
: > "$patch"
|
|
spatch --sp-file "$spatch" --use-gitgrep --dir "." --very-quiet --include-headers "$@" >> "$patch";
|
|
if [ "$(< "$patch" wc -l)" -gt "0" ]; then
|
|
cat "$patch"
|
|
ret=1
|
|
else
|
|
rm "$patch"
|
|
fi
|
|
done
|
|
|
|
exit $ret
|