summaryrefslogtreecommitdiffstats
path: root/mbbsd/mbbsd.c
diff options
context:
space:
mode:
Diffstat (limited to 'mbbsd/mbbsd.c')
-rw-r--r--mbbsd/mbbsd.c20
1 files changed, 3 insertions, 17 deletions
diff --git a/mbbsd/mbbsd.c b/mbbsd/mbbsd.c
index 8cef890c..804b2af3 100644
--- a/mbbsd/mbbsd.c
+++ b/mbbsd/mbbsd.c
@@ -98,36 +98,22 @@ reapchild(int sig)
}
void
-log_user(char *msg)
-{
- char filename[200], buf[200];
-
- snprintf(filename, sizeof(filename), BBSHOME "/home/%c/%s/USERLOG",
- cuser.userid[0], cuser.userid);
- snprintf(buf, sizeof(buf), "%s\n", msg);
- log_file(filename, msg, 1);
-}
-
-
-void
log_usies(char *mode, char *mesg)
{
- char genbuf[200];
if (!mesg)
- snprintf(genbuf, sizeof(genbuf),
+ log_file(FN_USIES, 1,
"%s %s %-12s Stay:%d (%s)\n",
Cdate(&now), mode, cuser.userid ,
(int)(now - login_start_time) / 60, cuser.username);
else
- snprintf(genbuf, sizeof(genbuf),
+ log_file(FN_USIES, 1,
"%s %s %-12s %s\n",
Cdate(&now), mode, cuser.userid, mesg);
- log_file(FN_USIES, genbuf, 1);
/* °lÂÜ¨Ï¥ÎªÌ */
if (HAS_PERM(PERM_LOGUSER))
- log_user(genbuf);
+ log_user("logout");
}