diff options
author | ptt <ptt@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2003-05-16 16:25:29 +0800 |
---|---|---|
committer | ptt <ptt@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2003-05-16 16:25:29 +0800 |
commit | cf62c6d70dcbe8cc6bb6cbf72377a60c2363e212 (patch) | |
tree | 9dfeccf0ebff5a565992d9b3ca4b40ffac86910a /mbbsd/friend.c | |
parent | 968a86a3b520514f2957e0cec6be6ea1c34487ea (diff) | |
download | pttbbs-cf62c6d70dcbe8cc6bb6cbf72377a60c2363e212.tar pttbbs-cf62c6d70dcbe8cc6bb6cbf72377a60c2363e212.tar.gz pttbbs-cf62c6d70dcbe8cc6bb6cbf72377a60c2363e212.tar.bz2 pttbbs-cf62c6d70dcbe8cc6bb6cbf72377a60c2363e212.tar.lz pttbbs-cf62c6d70dcbe8cc6bb6cbf72377a60c2363e212.tar.xz pttbbs-cf62c6d70dcbe8cc6bb6cbf72377a60c2363e212.tar.zst pttbbs-cf62c6d70dcbe8cc6bb6cbf72377a60c2363e212.zip |
*** empty log message ***
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk/pttbbs@857 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd/friend.c')
-rw-r--r-- | mbbsd/friend.c | 17 |
1 files changed, 10 insertions, 7 deletions
diff --git a/mbbsd/friend.c b/mbbsd/friend.c index e2616ec3..15fd35dc 100644 --- a/mbbsd/friend.c +++ b/mbbsd/friend.c @@ -1,4 +1,4 @@ -/* $Id: friend.c,v 1.17 2003/04/28 11:02:19 in2 Exp $ */ +/* $Id: friend.c,v 1.18 2003/05/16 08:25:10 ptt Exp $ */ #include "bbs.h" /* ------------------------------------- */ @@ -6,8 +6,8 @@ /* ------------------------------------- */ /* Ptt 其他特別名單的檔名 */ -static char special_list[] = "list.0"; -static char special_des[] = "ldes.0"; +char special_list[] = "list.0"; +char special_des[] = "ldes.0"; /* 特別名單的上限 */ static unsigned int friend_max[8] = { @@ -47,7 +47,7 @@ static char *friend_list[8] = { "看板好友名單" }; -static void +void setfriendfile(char *fpath, int type) { if (type <= 4) /* user list Ptt */ @@ -79,7 +79,7 @@ friend_count(char *fname) } void -friend_add(char *uident, int type) +friend_add(char *uident, int type, char* des) { char fpath[80]; @@ -96,7 +96,10 @@ friend_add(char *uident, int type) strlcpy(t_uident, uident, sizeof(t_uident)); if (type != FRIEND_ALOHA && type != FRIEND_POST) + if(!des) getdata(2, 0, friend_desc[type], buf, sizeof(buf), DOECHO); + else + getdata_str(2, 0, friend_desc[type], buf, sizeof(buf), DOECHO, des); if ((fp = fopen(fpath, "a"))) { flock(fileno(fp), LOCK_EX); @@ -107,7 +110,7 @@ friend_add(char *uident, int type) } } -static void +void friend_special() { char genbuf[70], i, fname[70]; @@ -370,7 +373,7 @@ friend_edit(int type) move(1, 0); usercomplete(msg_uid, uident); if (uident[0] && searchuser(uident) && !InNameList(uident)) { - friend_add(uident, type); + friend_add(uident, type, NULL); dirty = 1; } } else if (*uident == 'p') { |