Janes H provides a small workaround for a Palm tools bug.
[sgt/puzzles] / tents.c
diff --git a/tents.c b/tents.c
index b29fb22..7552b6b 100644 (file)
--- a/tents.c
+++ b/tents.c
@@ -875,7 +875,7 @@ static int tents_solve(int w, int h, const char *grid, int *numbers,
                            printf("%s %d forces %s at %d,%d\n",
                                   step==1 ? "row" : "column",
                                   step==1 ? start/w : start,
-                                  mrow[j] == TENT ? "tent" : "non-tent",
+                                  mthis[j] == TENT ? "tent" : "non-tent",
                                   pos % w, pos / w);
 #endif
                        soln[pos] = mthis[j];
@@ -1573,8 +1573,8 @@ static char *interpret_move(game_state *state, game_ui *ui, game_drawstate *ds,
                 int v = drag_xform(ui, x, y, state->grid[y*w+x]);
                 if (state->grid[y*w+x] != v) {
                     tmplen = sprintf(tmpbuf, "%s%c%d,%d", sep,
-                                     (v == BLANK ? 'B' :
-                                      v == TENT ? 'T' : 'N'),
+                                     (int)(v == BLANK ? 'B' :
+                                           v == TENT ? 'T' : 'N'),
                                      x, y);
                     sep = ";";