From: Michael Stapelberg Date: Mon, 7 Nov 2011 22:38:06 +0000 (+0000) Subject: complete-run: Bugfix: return condvar when $dont_start is true X-Git-Tag: 4.1~28^2~2 X-Git-Url: https://git.sur5r.net/?a=commitdiff_plain;h=8b887e8447c95b226d214bfe74cbc80137f297ab;p=i3%2Fi3 complete-run: Bugfix: return condvar when $dont_start is true --- diff --git a/testcases/complete-run.pl b/testcases/complete-run.pl index adef4837..2f05f703 100755 --- a/testcases/complete-run.pl +++ b/testcases/complete-run.pl @@ -165,11 +165,14 @@ sub take_job { } my $kill_i3 = sub { - # Don’t bother killing i3 when we haven’t started it - return if $dont_start; - my $kill_cv = AnyEvent->condvar; + # Don’t bother killing i3 when we haven’t started it + if ($dont_start) { + $kill_cv->send(); + return $kill_cv; + } + # When measuring code coverage, try to exit i3 cleanly (otherwise, .gcda # files are not written) and fallback to killing it if ($coverage_testing || $valgrind) {