From 9a6f35d1144f9f50bcc138716e91666af257d439 Mon Sep 17 00:00:00 2001 From: Markus Uhlin Date: Mon, 20 May 2024 00:16:32 +0200 Subject: Replaced the sprintf() calls --- FICS/gamedb.c | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/FICS/gamedb.c b/FICS/gamedb.c index 2d9914e..f8da9fd 100644 --- a/FICS/gamedb.c +++ b/FICS/gamedb.c @@ -1112,12 +1112,12 @@ ReadOneV1Move(FILE *fp, move_t *m) m->doublePawn = -1; if (m->pieceCaptured) { - sprintf(m->algString, "%cx%c%d", + msnprintf(m->algString, sizeof m->algString, "%cx%c%d", ('a' + m->fromFile), ('a' + m->toFile), (m->toRank + 1)); } else { - sprintf(m->algString, "%c%d", + msnprintf(m->algString, sizeof m->algString, "%c%d", ('a' + m->toFile), (m->toRank + 1)); } -- cgit v1.2.3