From b95812963a8d187526145f5e1a9693f10eee2b65 Mon Sep 17 00:00:00 2001 From: Khem Raj Date: Tue, 6 Dec 2016 01:22:00 +0000 Subject: Clarify conditions to avoid compiler errors Fix errors pointed out by clang error: logical not is only applied to the left hand side of this bitwise operator [-Werror,-Wlogical-not-parentheses] | if (only_immutable && !copy->flags[i] & FLAG_IMMUTABLE) continue; | ^ Signed-off-by: Khem Raj --- signpost.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'signpost.c') diff --git a/signpost.c b/signpost.c index aa2e13a..2e2dff2 100644 --- a/signpost.c +++ b/signpost.c @@ -284,7 +284,7 @@ static int check_nums(game_state *orig, game_state *copy, int only_immutable) int i, ret = 1; assert(copy->n == orig->n); for (i = 0; i < copy->n; i++) { - if (only_immutable && !copy->flags[i] & FLAG_IMMUTABLE) continue; + if (only_immutable && !(copy->flags[i] & FLAG_IMMUTABLE)) continue; assert(copy->nums[i] >= 0); assert(copy->nums[i] <= copy->n); if (copy->nums[i] != orig->nums[i]) { -- cgit v1.1