5 while [ ! -f $dir/wiggle
]
8 echo >&2 Cannot
find wiggle program
: $WIGGLE
13 export WIGGLE
=$dir/wiggle
19 vallog
=/tmp
/valg.log-$$
21 VG
="valgrind --log-file=$vallog"
27 find .
-name core |
xargs rm -f
28 list
=$
(find .
-type f
-name merge
)
30 WIGGLE
="$WIGGLE --self-test"
38 then $VG $WIGGLE -B orig
patch
40 then $VG $WIGGLE -B orig new new2
41 else $VG $WIGGLE -B orig
43 if grep 'ERROR SUMMARY: [1-9]' $vallog > /dev
/null
2>&1
44 then msg
="VALGRIND ERRORS"; xit
=1 ; mv $vallog $vallog-${dir////-}
45 else msg
="SUCCESS"; xit
=0
52 else status
=1 ; let fail
++
56 echo $ok succeeded and
$fail failed