]> rtime.felk.cvut.cz Git - lisovros/linux_canprio.git/commitdiff
ktest.pl: Fix combined usage of BISECT_REVERSE and BISECT_SKIP
authorRuss Dill <Russ.Dill@ti.com>
Tue, 24 Apr 2012 02:43:00 +0000 (19:43 -0700)
committerSteven Rostedt <rostedt@goodmis.org>
Tue, 1 May 2012 12:25:44 +0000 (08:25 -0400)
When BISECT_REVERSE and BISECT_SKIP are used together with boot or test
testing, build failures are treated as boot or test failures and
'git bisect bad' is executed instead of 'git bisect skip'. This is because
the $ret value of -1 is treated as a build failure, but the $reverse_bisect
logic does not properly handle this.

Simple fix, only invert it if it is positive.

Link: http://lkml.kernel.org/r/1335235380-8509-1-git-send-email-Russ.Dill@ti.com
Signed-off-by: Russ Dill <Russ.Dill@ti.com>
Signed-off-by: Steven Rostedt <rostedt@goodmis.org>
tools/testing/ktest/ktest.pl

index 95d6a6f7c33aa7971c50f9b107f0c8474a16d70a..d2ede59b9a3c8380d06625f3db163d4fc0ef5bd5 100755 (executable)
@@ -2192,7 +2192,7 @@ sub run_bisect {
     }
 
     # Are we looking for where it worked, not failed?
-    if ($reverse_bisect) {
+    if ($reverse_bisect && $ret >= 0) {
        $ret = !$ret;
     }