From 8c4c357f1830c246c1935c84aacc606e5d0762be Mon Sep 17 00:00:00 2001 From: Vicent Marti Date: Tue, 19 Jun 2012 02:43:36 +0200 Subject: clar: Fix warnings --- tests-clar/object/tree/write.c | 7 ++++++- 1 file changed, 6 insertions(+), 1 deletion(-) (limited to 'tests-clar/object/tree') diff --git a/tests-clar/object/tree/write.c b/tests-clar/object/tree/write.c index a7831203c..8b0f3417f 100644 --- a/tests-clar/object/tree/write.c +++ b/tests-clar/object/tree/write.c @@ -89,7 +89,8 @@ void test_object_tree_write__subtree(void) void test_object_tree_write__sorted_subtrees(void) { git_treebuilder *builder; - unsigned int i, position_c, position_cake, position_config; + unsigned int i; + int position_c = -1, position_cake = -1, position_config = -1; struct { unsigned int attr; @@ -140,6 +141,10 @@ void test_object_tree_write__sorted_subtrees(void) position_config = i; } + cl_assert(position_c != -1); + cl_assert(position_cake != -1); + cl_assert(position_config != -1); + cl_assert(position_c < position_cake); cl_assert(position_cake < position_config); -- cgit v1.2.1