diff options
Diffstat (limited to 'FICS/playerdb.c')
-rw-r--r-- | FICS/playerdb.c | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/FICS/playerdb.c b/FICS/playerdb.c index 084a1e7..f17593a 100644 --- a/FICS/playerdb.c +++ b/FICS/playerdb.c @@ -1211,6 +1211,11 @@ player_save(int p) FILE *fp; char fname[MAX_FILENAME_SIZE]; + if (!player_num_ok_chk(p)) { + warnx("%s: invalid player number %d", __func__, p); + return -1; + } + if (!parray[p].registered) // Player must not be registered return -1; |