Fail when spatch can't process source code

Sometimes spatch fails to process the source code:

    EXN: Failure("replacement: node 80: {7[1,2,30,31,32] in isc__nm_base64_to_base64url reachable by inconsistent control-flow paths") in ./lib/isc/netmgr/http.c

(cherry picked from commit 44d1a97870)
This commit is contained in:
Michal Nowak 2025-10-20 17:36:36 +02:00
parent c5a6ac6614
commit bbc05491f7

View file

@ -18,7 +18,7 @@ for spatch in cocci/*.spatch; do
echo "Applying semantic patch $spatch..."
spatch --jobs "${TEST_PARALLEL_JOBS:-1}" --sp-file "$spatch" --use-gitgrep --dir "." --very-quiet --include-headers "$@" >>"$patch" 2>cocci.stderr
cat cocci.stderr
if grep -q -e "parse error" cocci.stderr; then
if grep -q -e "parse error" -e "EXN: Failure" cocci.stderr; then
ret=1
fi
if [ "$(wc <"$patch" -l)" -gt "0" ]; then