summaryrefslogtreecommitdiffstats
path: root/mbbsd/user.c
diff options
context:
space:
mode:
authorpiaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2009-08-29 20:59:17 +0800
committerpiaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2009-08-29 20:59:17 +0800
commite40b5f174956a652514959e367df348c0ad66d9f (patch)
tree857b4187351c304433b8f79c1f7b4a506b0132f9 /mbbsd/user.c
parentf70549636d72d203ed0f50fb66688319c3fcb878 (diff)
downloadpttbbs-e40b5f174956a652514959e367df348c0ad66d9f.tar
pttbbs-e40b5f174956a652514959e367df348c0ad66d9f.tar.gz
pttbbs-e40b5f174956a652514959e367df348c0ad66d9f.tar.bz2
pttbbs-e40b5f174956a652514959e367df348c0ad66d9f.tar.lz
pttbbs-e40b5f174956a652514959e367df348c0ad66d9f.tar.xz
pttbbs-e40b5f174956a652514959e367df348c0ad66d9f.tar.zst
pttbbs-e40b5f174956a652514959e367df348c0ad66d9f.zip
* enable lastseen and CONST_CUSER, also use cuser_ref as "&cuser".
git-svn-id: http://opensvn.csie.org/pttbbs/branches/pttbbs.pwcu@4786 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd/user.c')
-rw-r--r--mbbsd/user.c11
1 files changed, 6 insertions, 5 deletions
diff --git a/mbbsd/user.c b/mbbsd/user.c
index 05071eea..c14d5bf1 100644
--- a/mbbsd/user.c
+++ b/mbbsd/user.c
@@ -1,4 +1,5 @@
/* $Id$ */
+#define PWCU_IMPL
#include "bbs.h"
static char * const sex[8] = {
@@ -79,7 +80,7 @@ int u_cancelbadpost(void)
if(search_ulistn(usernum,2))
{vmsg("請登出其他視窗, 否則不受理."); return 0;}
- passwd_sync_query(usernum, &cuser);
+ passwd_sync_query(usernum, cuser_ref);
if (currutmp && (currutmp->alerts & ALERT_PWD))
currutmp->alerts &= ~ALERT_PWD;
@@ -104,7 +105,7 @@ int u_cancelbadpost(void)
{
int prev = cuser.badpost--;
cuser.timeremovebadpost = now;
- passwd_sync_update(usernum, &cuser);
+ passwd_sync_update(usernum, cuser_ref);
log_filef("log/cancelbadpost.log", LOG_CREAT,
"%s %s 刪除一篇劣文 (%d -> %d 篇)\n",
Cdate(&now), cuser.userid, prev, cuser.badpost);
@@ -526,7 +527,7 @@ void Customize(void)
if(dirty)
{
- passwd_sync_update(usernum, &cuser);
+ passwd_sync_update(usernum, cuser_ref);
outs("設定已儲存。\n");
} else {
outs("結束設定。\n");
@@ -1123,8 +1124,8 @@ u_info(void)
{
move(2, 0);
reload_money();
- user_display(&cuser, 0);
- uinfo_query(&cuser, 0, usernum);
+ user_display(cuser_ref, 0);
+ uinfo_query (cuser_ref, 0, usernum);
strlcpy(currutmp->nickname, cuser.nickname, sizeof(currutmp->nickname));
return 0;
}