Skip to contentSkip to conversation

master - tests: hide error output

PATCH Zdenek Kabelac 1 participant 1 message Apr 15, 2015

lore
Share & tools
lore
#0 lore raw
Gitweb:        http://git.fedorahosted.org/git/?p=lvm2.git;a=commitdiff;h=5d4695569d58f42dfc95feda55e463ebcbf03ffb
Commit:        5d4695569d58f42dfc95feda55e463ebcbf03ffb
Parent:        930f0aae845e65f3673d14df97e141baccf37849
Author:        Zdenek Kabelac <[email protected]>
AuthorDate:    Wed Apr 15 13:10:33 2015 +0200
Committer:     Zdenek Kabelac <[email protected]>
CommitterDate: Wed Apr 15 13:35:42 2015 +0200

tests: hide error output

Hide error message if pid is already away.

---
 test/lib/aux.sh |    2 +-
 1 files changed, 1 insertions(+), 1 deletions(-)
test/lib/aux.sh +1 -1
index 505d15e..c28ac7b 100644
@@ -218,7 +218,7 @@ kill_sleep_kill_() {
 	slow=$2
 	if test -s $pidfile ; then
 		pid=$(< $pidfile)
-		kill -TERM $pid || return 0
+		kill -TERM $pid 2>/dev/null || return 0
 		if test $slow -eq 0 ; then sleep .1 ; else sleep 1 ; fi
 		kill -KILL $pid 2>/dev/null || true
 		wait=0