From: Carl Worth Date: Sat, 23 Feb 2008 19:21:24 +0000 (-0800) Subject: Fix segfault when formatting "Illegal move" message. X-Git-Url: https://git.cworth.org/git?p=loudgame;a=commitdiff_plain;h=8c682e3290eb67aa6e036fb83df92fbc1003e22f Fix segfault when formatting "Illegal move" message. --- diff --git a/lg-loa.c b/lg-loa.c index f6a8f4c..a1949d3 100644 --- a/lg-loa.c +++ b/lg-loa.c @@ -412,7 +412,9 @@ loa_game_move (loa_game_t *game, const char * peer, } if (! board_move_legal (&game->board, x1, y1, x2, y2, &error)) { - loudgame_sendf (&game->lg, peer, "Illegal move: %s."); + loudgame_sendf (&game->lg, peer, "Illegal move: %c%d%c%d", + 'a' + x1, BOARD_SIZE - y1, + 'a' + x2, BOARD_SIZE - y2); return FALSE; }