From e25019012adf506a5cc15a43d7e322c038367505 Mon Sep 17 00:00:00 2001 From: Petr Baudis Date: Wed, 17 Sep 2008 23:13:29 +0200 Subject: [PATCH] check_libs_consistency(): Do not consider empty spots in lib[] --- board.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/board.c b/board.c index f597d74..04063ec 100644 --- a/board.c +++ b/board.c @@ -300,7 +300,7 @@ check_libs_consistency(struct board *board, group_t g) if (!g) return; struct group *gi = &board_group_info(board, g); for (int i = 0; i < gi_libs_bound(*gi); i++) - if (board_at(board, gi->lib[i]) != S_NONE) { + if (gi->lib[i] && board_at(board, gi->lib[i]) != S_NONE) { fprintf(stderr, "BOGUS LIBERTY %s of group %d[%s]\n", coord2sstr(gi->lib[i], board), g, coord2sstr(g, board)); assert(0); } -- 2.11.4.GIT