Web   ·   Wiki   ·   Activities   ·   Blog   ·   Lists   ·   Chat   ·   Meeting   ·   Bugs   ·   Git   ·   Translate   ·   Archive   ·   People   ·   Donate
summaryrefslogtreecommitdiffstats
path: root/src/boards
diff options
context:
space:
mode:
authorWolfram Sang <wolfram@iswi.org>2009-06-18 22:14:02 (GMT)
committer Bruno Coudoin <bruno.coudoin@free.fr>2009-06-18 22:14:02 (GMT)
commit17e1ae7854b468b6ed1d89809de1159c993c2291 (patch)
treef41e24ff06521b3ef29689dfa62afac1e30c669e /src/boards
parenta248850b0b8bfd96a5a50d3fbaa4be8ce7c22070 (diff)
Fix an off-by-one bug in the calculation of the amount of levels, which made it
possible to see the end-sequence just by clicking the dice.
Diffstat (limited to 'src/boards')
-rw-r--r--src/boards/shapegame.c6
1 files changed, 2 insertions, 4 deletions
diff --git a/src/boards/shapegame.c b/src/boards/shapegame.c
index e27bed8..d6e69f4 100644
--- a/src/boards/shapegame.c
+++ b/src/boards/shapegame.c
@@ -261,14 +261,12 @@ static void start_board (GcomprisBoard *agcomprisBoard)
/**/
while( (filename = gc_file_find_absolute("%s/board%d_0.xml",
gcomprisBoard->boarddir,
- gcomprisBoard->maxlevel++,
+ gcomprisBoard->maxlevel,
NULL)) )
{
+ gcomprisBoard->maxlevel++;
g_free(filename);
-
}
-
- /**/
gcomprisBoard->maxlevel--;
gc_bar_set(GC_BAR_CONFIG|GC_BAR_LEVEL);