#!/bin/sh -
#
# $Id: chk.rr,v 1.3 2003/08/01 17:01:11 bostic Exp $

d=../..

t1=__1

# Check for DB_RUNRECOVERY being specified instead of a call to db_panic.
egrep DB_RUNRECOVERY $d/*/*.c |
    sed -e '/common\/db_err.c:/d' \
        -e '/case DB_RUNRECOVERY:/d' \
	-e '/db_dispatch.c:.*if (ret == DB_RUNRECOVERY/d' \
	-e '/os_errno.c:.*evalue == DB_RUNRECOVERY/d' \
	-e '/txn.c:.* \* DB_RUNRECOVERY and we need to/d' \
	-e '/__db_panic(.*, DB_RUNRECOVERY)/d' > $t1
[ -s $t1 ] && {
	echo "DB_RUNRECOVERY used; should be a call to db_panic."
	cat $t1
	exit 1
}

exit 0
