[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]
2.05b: incorrect $? occasionally?
From: |
Marshall, Simon |
Subject: |
2.05b: incorrect $? occasionally? |
Date: |
Tue, 9 Sep 2003 09:58:24 +0100 |
Hi, this is a bit vague because I can't reproduce it on demand. But I
thought I'd raise it anyway.
This is with 2.05b.0(1)-release (i586-suse-linux).
We have a script containing the function:
execute_run ()
{
cmd="$exe -p $tmp/paths.dat > $tmp/CARMA.OUT 2> $tmp/CARMA.ERR"
cd $dir
if [ ${tim:-0} -le 0 ]
then
eval $cmd
else
time=$(ksh -c "time $cmd" 2>&1)
fi
status=$?
}
The script runs nightly and calls this function 800+ times (in this
environment running "eval $cmd" each time). Maybe once a week, maybe
more, $status has a non-zero value (though $status & 128 is zero so
there seems to be no signal involved) for one of the runs (not the same
one each time). I'm sure as I can be that $cmd did exit with
EXIT_SUCCESS; if it didn't then other things would have shown up in
other logs. When I repeat the run in the morning, $status is zero. The
only conclusion I can make is that $? is occasionally wrong.
Does this ring a bell with anyone? Thanks, Simon.
[Prev in Thread] |
Current Thread |
[Next in Thread] |
- 2.05b: incorrect $? occasionally?,
Marshall, Simon <=