[CRIU] [PATCH cr 1/2] zdtm: don't show a wrong path to log files

Andrey Vagin avagin at openvz.org
Fri May 11 15:02:34 EDT 2012


It showed old pathes.

Dump log   : /root/crtools/test/dump/inotify00/15673/dump.log
Restore log: /root/crtools/test/dump/inotify00/15673/restore.log
Output file: /root/crtools/test/zdtm/live/static/utsname.out
make: *** [test] Error 1

Signed-off-by: Andrey Vagin <avagin at openvz.org>
---
 test/zdtm.sh |   11 +++++++----
 1 files changed, 7 insertions(+), 4 deletions(-)

diff --git a/test/zdtm.sh b/test/zdtm.sh
index 0a55566..eb138cd 100644
--- a/test/zdtm.sh
+++ b/test/zdtm.sh
@@ -83,6 +83,7 @@ run_test()
 	local args=$*
 	local tname=`basename $test`
 	local tdir=`dirname $test`
+	DUMP_PATH=""
 
 	echo "Execute $test"
 
@@ -138,10 +139,12 @@ case_error()
 	echo "Test: $test"
 	echo "====================== ERROR ======================"
 
-	[ -e "$DUMP_PATH/dump.log" ] &&
-		echo "Dump log   : $DUMP_PATH/dump.log"
-	[ -e "$DUMP_PATH/restore.log" ] &&
-		echo "Restore log: $DUMP_PATH/restore.log"
+	if [ -n "$DUMP_PATH" ]; then
+		[ -e "$DUMP_PATH/dump.log" ] &&
+			echo "Dump log   : $DUMP_PATH/dump.log"
+		[ -e "$DUMP_PATH/restore.log" ] &&
+			echo "Restore log: $DUMP_PATH/restore.log"
+	fi
 	[ -e "$test_log" ] &&
 		echo "Output file: $test_log"
 	exit 1
-- 
1.7.1



More information about the CRIU mailing list