X-Git-Url: http://git.alex.org.uk diff --git a/simple_test b/simple_test index a01d3dc..0f12126 100755 --- a/simple_test +++ b/simple_test @@ -2,6 +2,8 @@ # Yes, that's POSIX sh, not bash! tmpnam=`mktemp` +conffile=${tmpnam}.conf +pidfile=${tmpnam}.pid ulimit -c unlimited @@ -13,7 +15,7 @@ echo $1 case $1 in */cmd) # Test with export specified on command line - ./nbd-server -C /dev/null -p `pwd`/nbd-server.pid 11111 $tmpnam & + ./nbd-server -C /dev/null -p ${pidfile} 11111 $tmpnam & # -p only works if nbd-server wasn't compiled with -DNOFORK or # -DNODAEMON, which I sometimes do for testing and debugging. PID=$! @@ -23,7 +25,7 @@ case $1 in ;; */cfgsize) # Test oversized requests - ./nbd-server -C /dev/null -p `pwd`/nbd-server.pid 11111 $tmpnam & + ./nbd-server -C /dev/null -p ${pidfile} 11111 $tmpnam & # -p only works if nbd-server wasn't compiled with -DNOFORK or # -DNODAEMON, which I sometimes do for testing and debugging. PID=$! @@ -33,14 +35,14 @@ case $1 in ;; */cfg1) # Test with export specified in config file - cat > nbd-server.conf < ${conffile} <nbd-server.conf <${conffile} <nbd-server.conf <${conffile} <nbd-server.conf <${conffile} <nbd-server.conf <${conffile} <