Commit fc1826d149faee191adf38d6a91d5a9fa7c8cddc

Carlos Martín Nieto 2012-08-14T20:54:13

tests: fix tree walking test Return -1 to stop the iteration instead of not-0

1
2
3
4
5
6
7
8
9
10
11
12
13
diff --git a/tests-clar/object/tree/walk.c b/tests-clar/object/tree/walk.c
index a0ea64c..58b0bca 100644
--- a/tests-clar/object/tree/walk.c
+++ b/tests-clar/object/tree/walk.c
@@ -59,7 +59,7 @@ static int treewalk_stop_cb(
 
 	(*count) += 1;
 
-	return (*count == 2);
+	return (*count == 2) ? -1 : 0;
 }
 
 static int treewalk_stop_immediately_cb(