Skip to contentSkip to conversation

LVM2/test/lib aux.sh

PATCH [email protected] 1 participant 1 message Jan 12, 2011

lore
Share & tools
lore
#0 lore raw

CVSROOT: /cvs/lvm2
Module name: LVM2
Changes by: mornfall at sourceware.org 2011-01-12 16:07:56

Modified files:
test/lib : aux.sh

Log message:
Kill clvmd properly after locking_type 3 tests (using clvmd/singlenode).

Patches:
http://sourceware.org/cgi-bin/cvsweb.cgi/LVM2/test/lib/aux.sh.diff?cvsroot=lvm2&r1=1.5&r2=1.6

test/lib/aux.sh +4 -3
@@ -32,6 +32,7 @@
 	# check that it is really running now
 	sleep .1
 	ps $LOCAL_CLVMD || skip
+        echo "$LOCAL_CLVMD" > LOCAL_CLVMD
 }
 
 prepare_dmeventd() {
@@ -83,10 +84,10 @@
 teardown() {
     echo -n "## teardown..."
 
-    test -n "$LOCAL_CLVMD" && {
-	kill "$LOCAL_CLVMD"
+    test -f LOCAL_CLVMD && {
+	kill "$(cat LOCAL_CLVMD)"
 	sleep .1
-	kill -9 "$LOCAL_CLVMD" || true
+	kill -9 "$(cat LOCAL_CLVMD)" || true
     }
 
     echo -n .