X-Git-Url: https://git.distorted.org.uk/~mdw/sgt/puzzles/blobdiff_plain/4b0cf9034e4e73a42d48326ec6f6fca3023a0661..48a10826fef7777bb8b061f4a121f481ced98bc0:/sixteen.c diff --git a/sixteen.c b/sixteen.c index cd6ae3b..950f724 100644 --- a/sixteen.c +++ b/sixteen.c @@ -429,7 +429,7 @@ static char *game_text_format(game_state *state) */ maxlen = state->h * state->w * (col+1); - ret = snewn(maxlen, char); + ret = snewn(maxlen+1, char); p = ret; for (y = 0; y < state->h; y++) {