diff options
author | Markus Uhlin <markus@nifty-networks.net> | 2024-07-17 19:31:15 +0200 |
---|---|---|
committer | Markus Uhlin <markus@nifty-networks.net> | 2024-07-17 19:31:15 +0200 |
commit | d71f5d9bbdf2cc359ecfd23a8f559c0f3e212d05 (patch) | |
tree | f623ccae0813f1e7240cfee6c77c3ab51aabf4e6 /FICS | |
parent | c98c40a47c6f1c522a485d2610e51267541adc52 (diff) |
accept_match: added check
Diffstat (limited to 'FICS')
-rw-r--r-- | FICS/matchproc.c | 12 |
1 files changed, 12 insertions, 0 deletions
diff --git a/FICS/matchproc.c b/FICS/matchproc.c index 58948a3..adbe5df 100644 --- a/FICS/matchproc.c +++ b/FICS/matchproc.c @@ -35,6 +35,7 @@ #include <sys/resource.h> +#include <err.h> #include <string.h> #include "board.h" @@ -500,6 +501,17 @@ accept_match(int p, int p1) } else { // resume adjourned game game_delete(p, p1); + // XXX: must be either + if (garray[g].rated != TYPE_UNRATED && + garray[g].rated != TYPE_RATED) { + warnx("%s: adjourned game neither rated/unrated", + __func__); + warnx("%s: %s vs %s", __func__, + parray[p].name, + parray[p1].name); + garray[g].rated = TYPE_UNRATED; + } + snprintf(tmp, sizeof tmp, "{Game %d (%s vs. %s) Continuing " "%s %s match.}\n", (g + 1), |