#!/usr/bin/sh
#
# M. Hayes 2/28/97
#
# Output data that a real SCSI_log_sense command would have.
# Read in from the counter file to determine which data file to output
#
COUNTER=`cat $1/simcounter.dat`
RESULT=`cat $1/SA_DEFAULT/SCSI_log_sense$COUNTER.dat`
echo "$RESULT"
echo "$RESULT" | awk '$1 == "ERROR:Check" {exit 2}' -
if [ $? -eq 2 ]; then
   exit 2;
fi
echo "$RESULT" | awk '$1 == "ERROR:System" {exit 1}' -
if [ $? -eq 1 ]; then
   exit 1;
fi
