chiark / gitweb /
Validation of random-state-type game descriptions was broken. This
authorSimon Tatham <anakin@pobox.com>
Wed, 29 Jun 2005 12:19:08 +0000 (12:19 +0000)
committerSimon Tatham <anakin@pobox.com>
Wed, 29 Jun 2005 12:19:08 +0000 (12:19 +0000)
meant that a Mines game saved before the first click had taken place
could not be successfully reloaded.

[originally from svn r6036]

mines.c

diff --git a/mines.c b/mines.c
index 612ade5efe1e216ebb9d7d6004ec405e2cccab30..d2ec3958a52122127bb76eff2c0a1aa0cd99b1fa 100644 (file)
--- a/mines.c
+++ b/mines.c
@@ -1990,6 +1990,7 @@ static char *validate_desc(game_params *params, char *desc)
     int x, y;
 
     if (*desc == 'r') {
+        desc++;
        if (!*desc || !isdigit((unsigned char)*desc))
            return "No initial mine count in game description";
        while (*desc && isdigit((unsigned char)*desc))