diff options
author | victor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2005-07-04 14:52:14 +0800 |
---|---|---|
committer | victor <victor@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2005-07-04 14:52:14 +0800 |
commit | 7204388338e4e7445afd399a2e1c4947f86fbce3 (patch) | |
tree | acb927d31a747670a3ad1af593d537046581cb45 /util | |
parent | ff7b952f0b6628d4843bd0cf4ceb8e9efd7798aa (diff) | |
download | pttbbs-7204388338e4e7445afd399a2e1c4947f86fbce3.tar pttbbs-7204388338e4e7445afd399a2e1c4947f86fbce3.tar.gz pttbbs-7204388338e4e7445afd399a2e1c4947f86fbce3.tar.bz2 pttbbs-7204388338e4e7445afd399a2e1c4947f86fbce3.tar.lz pttbbs-7204388338e4e7445afd399a2e1c4947f86fbce3.tar.xz pttbbs-7204388338e4e7445afd399a2e1c4947f86fbce3.tar.zst pttbbs-7204388338e4e7445afd399a2e1c4947f86fbce3.zip |
apply rafan's (rafan.bbs@ptt2.cc) big patch to s/username/nickname/g
turn off FOREIGN_REG by default in sample/pttbbs.conf
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@2887 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'util')
-rw-r--r-- | util/birth.c | 2 | ||||
-rw-r--r-- | util/passwdconverter.c | 4 | ||||
-rw-r--r-- | util/topusr.c | 10 | ||||
-rw-r--r-- | util/userlist.c | 2 | ||||
-rw-r--r-- | util/xchatd.c | 2 |
5 files changed, 10 insertions, 10 deletions
diff --git a/util/birth.c b/util/birth.c index 8f4530f0..f0d5626a 100644 --- a/util/birth.c +++ b/util/birth.c @@ -82,7 +82,7 @@ int main(argc, argv) fprintf(fp1, " [33m[%2d/%-2d] %-14s[0m %-24s login:%-5d post:%-5d\n", ptime->tm_mon + 1, ptime->tm_mday, user.userid, - user.username, user.numlogins, user.numposts); + user.nickname, user.numlogins, user.numposts); } } } diff --git a/util/passwdconverter.c b/util/passwdconverter.c index 86836d1f..7cd60cbe 100644 --- a/util/passwdconverter.c +++ b/util/passwdconverter.c @@ -4,7 +4,7 @@ typedef struct old_userec_t { char userid[IDLEN + 1]; char realname[20]; - char username[24]; + char nickname[24]; char passwd[PASSLEN]; unsigned char uflag; unsigned int userlevel; @@ -60,7 +60,7 @@ void transform(userec_t *new, old_userec_t *old) strlcpy(new->userid, old->userid, IDLEN + 1); strlcpy(new->realname, old->realname, 20); - strlcpy(new->username, old->username, 24); + strlcpy(new->nickname, old->nickname, 24); strlcpy(new->passwd, old->passwd, PASSLEN); new->uflag = old->uflag; new->userlevel = old->userlevel; diff --git a/util/topusr.c b/util/topusr.c index cbd5098f..d2679d39 100644 --- a/util/topusr.c +++ b/util/topusr.c @@ -7,7 +7,7 @@ struct manrec { char userid[IDLEN + 1]; - char username[23]; + char nickname[23]; int values[3]; }; typedef struct manrec manrec; @@ -49,7 +49,7 @@ void { value=allman[type][i].values[type]/1000; ch='K';} else {value=allman[type][i].values[type]; ch=' ';} sprintf(buf1, "[%2d] %-11.11s%-16.16s%5d%c", - i + 1, allman[type][i].userid, allman[type][i].username, + i + 1, allman[type][i].userid, allman[type][i].nickname, value, ch); j = i + rows; if(allman[type][j].values[type] > 1000000000) @@ -59,7 +59,7 @@ void else {value=allman[type][j].values[type]; ch=' ';} sprintf(buf2, "[%2d] %-11.11s%-16.16s%4d%c", - j + 1, allman[type][j].userid, allman[type][j].username, + j + 1, allman[type][j].userid, allman[type][j].nickname, value, ch); if (i < 3) fprintf(fp, "\n [1;%dm%-40s[0;37m%s", 31 + i, buf1, buf2); @@ -135,7 +135,7 @@ int main(int argc, char **argv) for(j = 1; j <= MAX_USERS; j++) { passwd_query(j, &aman); aman.userid[IDLEN]=0; - aman.username[22]=0; + aman.nickname[22]=0; if((aman.userlevel & PERM_NOTOP) || !aman.userid[0] || bad_user_id(aman.userid) || strchr(aman.userid, '.')) @@ -144,7 +144,7 @@ int main(int argc, char **argv) } else { strcpy(theman.userid, aman.userid); - strcpy(theman.username, aman.username); + strcpy(theman.nickname, aman.nickname); theman.values[TYPE_LOGIN] = aman.numlogins; theman.values[TYPE_POST] = aman.numposts; theman.values[TYPE_MONEY] = aman.money; diff --git a/util/userlist.c b/util/userlist.c index 8c701478..3faf5364 100644 --- a/util/userlist.c +++ b/util/userlist.c @@ -33,7 +33,7 @@ int main(int argc, char **argv) { printf( "%4d(%d) p[%d] i[%d] u[%s] n[%s] f[%s] m[%d] t[%d]\n", ++counter, i, f->pager, f->invisible, f->userid, - f->username, f->from, f->mode, f->lastact); + f->nickname, f->from, f->mode, f->lastact); } printf("\nTotal: %d(%d)\n", counter, SHM->number); if(counter != SHM->number) { diff --git a/util/xchatd.c b/util/xchatd.c index d0b4cad4..8e2373b5 100644 --- a/util/xchatd.c +++ b/util/xchatd.c @@ -735,7 +735,7 @@ chat_query(ChatUser *cu, char *msg) if (acct_load(&xuser, msg) >= 0) { snprintf(chatbuf, sizeof(chatbuf), "%s(%s) 共上站 %d 次,文章 %d 篇", - xuser.userid, xuser.username, xuser.numlogins, xuser.numposts); + xuser.userid, xuser.nickname, xuser.numlogins, xuser.numposts); send_to_user(cu, chatbuf, 0, MSG_MESSAGE); snprintf(chatbuf, sizeof(chatbuf), "最近(%s)從(%s)上站", Ctime(&xuser.lastlogin), |