diff options
author | victor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2003-05-09 15:53:55 +0800 |
---|---|---|
committer | victor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2003-05-09 15:53:55 +0800 |
commit | ff3afd480dad5adc0404dc2a747508de95c5c32e (patch) | |
tree | c207ba3641d7ac2462d292293ff0c4292524e3d7 /mbbsd | |
parent | 5da31363b72ee7074a281ea7b216e470124a32bf (diff) | |
download | pttbbs-ff3afd480dad5adc0404dc2a747508de95c5c32e.tar pttbbs-ff3afd480dad5adc0404dc2a747508de95c5c32e.tar.gz pttbbs-ff3afd480dad5adc0404dc2a747508de95c5c32e.tar.bz2 pttbbs-ff3afd480dad5adc0404dc2a747508de95c5c32e.tar.lz pttbbs-ff3afd480dad5adc0404dc2a747508de95c5c32e.tar.xz pttbbs-ff3afd480dad5adc0404dc2a747508de95c5c32e.tar.zst pttbbs-ff3afd480dad5adc0404dc2a747508de95c5c32e.zip |
fix last commit bug
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk/pttbbs@829 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd')
-rw-r--r-- | mbbsd/mbbsd.c | 17 |
1 files changed, 9 insertions, 8 deletions
diff --git a/mbbsd/mbbsd.c b/mbbsd/mbbsd.c index 9c360550..77dc98e3 100644 --- a/mbbsd/mbbsd.c +++ b/mbbsd/mbbsd.c @@ -1,4 +1,4 @@ -/* $Id: mbbsd.c,v 1.72 2003/05/09 07:43:57 victor Exp $ */ +/* $Id: mbbsd.c,v 1.73 2003/05/09 07:53:55 victor Exp $ */ #include "bbs.h" #define SOCKET_QLEN 4 @@ -884,14 +884,15 @@ user_login() if (!PERM_HIDE(currutmp)) cuser.lastlogin = login_start_time; - if (login_start_time - cuser.firstlogin > (FOREIGN_REG_DAY - 5) * 24 * 3600){ - mail_muser(cuser, "[出入境管理局]", "etc/foreign_expired_warn"); - } - else if (login_start_time - cuser.firstlogin > FOREIGN_REG_DAY * 24 * 3600){ - cuser.userlevel &= ~(PERM_LOGINOK | PERM_POST); - mail_muser(cuser, "[出入境管理局]", "etc/foreign_expired"); + if (cuser.foreign & FOREIGN){ + if (login_start_time - cuser.firstlogin > (FOREIGN_REG_DAY - 5) * 24 * 3600){ + mail_muser(cuser, "[出入境管理局]", "etc/foreign_expired_warn"); + } + else if (login_start_time - cuser.firstlogin > FOREIGN_REG_DAY * 24 * 3600){ + cuser.userlevel &= ~(PERM_LOGINOK | PERM_POST); + mail_muser(cuser, "[出入境管理局]", "etc/foreign_expired"); + } } - passwd_update(usernum, &cuser); for (i = 0; i < NUMVIEWFILE; i++) |