It's tricky I found that out (thus the absolute path). I expect the more "rational" thing might be to have pan open the log file(s) before changing to it's tmp directory.

Jay Huie
 zSeries Linux System Test
 Phone: 845-435-8164

Sent by:

To:        "V.R.Sundar" <>
Subject:        Re: [LTP] Re: results comparator? (Dan Kegel)

V.R.Sundar wrote:
> On Mon, 2003-01-27 at 10:27, William Jay Huie wrote:
>>        ltprun calls with the appropriate parameters.
>>                ./ -l ~/ltp/$LTP_LOGFILE &>
> Ok. Found the difference. I was running it as:
> ./ -l ltp.log
> The difference being you were giving a full path. The script
> creates and moves to a temp directory before running pan
> and then deletes it at the end. So the log file was created there and
> then deleted.

It might be helpful to add a check in to abort if
-l is given a nonabsolute path, e.g.

case $log in
*/*) ;;
*) echo "absolute path required"; exit 1 ;;

(Alternately, to use crap like
logdir=`dirname $log`
logdir=`cd $logdir; pwd`
log=$logdir/`basename $log`
to convert the logfile name to an absolute path... that's going a bit too far, though...)

Dan Kegel

This SF.NET email is sponsored by:
SourceForge Enterprise Edition + IBM + LinuxWorld = Something 2 See!
Ltp-list mailing list