Fixed compiler warning on Alpine using musl libc.

This commit is contained in:
Johannes Findeisen 2026-11-27 01:22:58 +01:00
commit 8feaa4b18d

3
irc9.c
View file

@ -1364,7 +1364,8 @@ static void history_add(const char *s)
{
if (!*s) return;
if (hist_n == MAXHIST) {
memmove(history[0], history[1], (MAXHIST - 1) * MAXINPUT);
for (int i = 1; i < MAXHIST; i++)
memcpy(history[i - 1], history[i], sizeof history[i]);
hist_n--;
}
snprintf(history[hist_n++], MAXINPUT, "%s", s);