diff options
Diffstat (limited to 'mbbsd/chat.c')
-rw-r--r-- | mbbsd/chat.c | 5 |
1 files changed, 2 insertions, 3 deletions
diff --git a/mbbsd/chat.c b/mbbsd/chat.c index 744efa7d..66238334 100644 --- a/mbbsd/chat.c +++ b/mbbsd/chat.c @@ -381,9 +381,8 @@ t_chat() print_chatid(chatid); memset(inbuf, 0, sizeof(inbuf)); - sethomepath(fpath, cuser->userid); - strlcpy(fpath, tempnam(fpath, "chat_"), sizeof(fpath)); - flog = fopen(fpath, "w"); + setuserfile(fpath, "chat_XXXXXX"); + flog = fdopen(mkstemp(fpath), "w"); while (chatting) { move(b_lines - 1, currchar + chatid_len); |