shithub: puzzles

Download patch

ref: 6d96375736a2991d61df292ae38adcc010b860bf
parent: 0e68ad82a9f514a987c1d56efac6387792d2ec07
author: Simon Tatham <anakin@pobox.com>
date: Mon Jul 18 14:54:06 EDT 2005

Fix to Chris's patch in r6106 (also from Chris).

[originally from svn r6117]
[r6106 == a31934f233581da07153af6b4ee717f1e63387dd]

--- a/rect.c
+++ b/rect.c
@@ -2477,6 +2477,9 @@
 	vedge(ret,x1,y1) = !vedge(ret,x1,y1);
     }
 
+    sfree(ret->correct);
+    ret->correct = get_correct(ret);
+
     /*
      * We've made a real change to the grid. Check to see
      * if the game has been completed.
@@ -2493,9 +2496,6 @@
 	if (ok)
 	    ret->completed = TRUE;
     }
-
-    sfree(ret->correct);
-    ret->correct = get_correct(ret);
 
     return ret;
 }