#!/bin/sh
PATH=/sbin:/usr/sbin:/bin:/usr/bin:/etc:/usr/etc export PATH
if [ -f $BASEDIR/etc/sendmail.fc ]; then
	rm -f $BASEDIR/etc/sendmail.fc
	/usr/lib/sendmail -bz
fi
x=`grep sendmail /etc/rc.local | grep echo | cut -d";" -f1` 
y=`ps -aux | grep sendmail | grep -v grep | awk '{print $2}'`
echo restarting sendmail, old pid $y
kill $y
echo $x
eval $x
y=`ps -aux | grep sendmail | grep -v grep | awk '{print $2}'`
echo new sendmail pid is $y
chmod 0755 /bin/mail
echo /bin/mail setuid disabled.
exit 0
