#err()
DESCRIPTION returns the error value ERR
SYNOPSIS
#err()
ARGUMENTS none
EXAMPLES
rule // check validity of fsck pass
if $fstype eq "ufs"
set #fp = #val($fsckpass)
if ( #fp == #err() )
|| ! =isint(#fp)
|| #fp !> 0
output mail "bad fsck pass: $inlin"
fi
fi
rule
=set_hr($inlin)
...
rule // report corrupted lines, then bypass
if #hr == #err()
output mail $inlin
next
endif
rule // for changed scripts, diff and log/mail any changes
if #popen(DIFF, "=diff $hstfil $fil", "r") != #err()
while #read(DIFF) > 0
if #doheader
output mail "changes to $fil:"
output log "(L)" "changes to $fil:"
set #doheader = #false()
fi
output mail $rdlin
output log "(L)" $rdlin
endwhile
do #pclose(DIFF)
else
output mail "can't open process for reading!"
quit
fi
SEE ALSO #defined() #error() #nil() Numerical Functions String Functions