From a8207490ca0ba62ba301edd6f034837ef01bc7cf Mon Sep 17 00:00:00 2001 From: piaip Date: Fri, 22 Jul 2005 15:53:44 +0000 Subject: adjust cp log color/style and we should update board record. git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@2940 63ad8ddf-47c3-0310-b6dd-a9e9d9715204 --- mbbsd/bbs.c | 10 ++++++---- mbbsd/friend.c | 8 ++++---- 2 files changed, 10 insertions(+), 8 deletions(-) diff --git a/mbbsd/bbs.c b/mbbsd/bbs.c index d5d94e81..e468e78d 100644 --- a/mbbsd/bbs.c +++ b/mbbsd/bbs.c @@ -1177,7 +1177,7 @@ cross_post(int ent, fileheader_t * fhdr, const char *direct) char buf[MAXPATHLEN]; char bname[IDLEN+1] = "", *pbname = bname; struct tm *ptime = localtime4(&now); - int maxlength = 51 +2 -14; + int maxlength = 51 +2 - 11; strcpy(bname, xboard); if ((bp->brdattr & BRD_HIDE) && (bp->brdattr & BRD_POSTMASK)) @@ -1187,9 +1187,11 @@ cross_post(int ent, fileheader_t * fhdr, const char *direct) maxlength -= (strlen(cuser.userid) + strlen(bname)); snprintf(buf, sizeof(buf), - ANSI_COLOR(1;31) "→ " ANSI_COLOR(33) "%s" - ANSI_RESET ANSI_COLOR(32) - ":轉錄至看板「%s」" ANSI_RESET "%*s" + // ANSI_COLOR(32) <- system will add green + "※ " ANSI_COLOR(1) "%s" + ANSI_COLOR(0;32) + ":轉錄至看板 " ANSI_COLOR(1) + "%s" ANSI_RESET "%*s" "%15s %02d/%02d\n", cuser.userid, bname, maxlength, "", fromhost, ptime->tm_mon + 1, ptime->tm_mday); diff --git a/mbbsd/friend.c b/mbbsd/friend.c index 407560e0..9d87ee8f 100644 --- a/mbbsd/friend.c +++ b/mbbsd/friend.c @@ -448,12 +448,12 @@ friend_edit(int type) fclose(fp); } } else if (type == BOARD_WATER) { + currbid = getbnum(currboard); boardheader_t *bp = - getbcache(getbnum(currboard)); + getbcache(currbid); bp->perm_reload = now; - /* should we flush perm_reload? - * not really important in current implementation. - */ + substitute_record(fn_board, bp, sizeof(boardheader_t), currbid); + // log_usies("SetBoard", bp->brdname); } friend_load(0); } -- cgit v1.2.3