diff options
author | piaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2005-06-13 14:51:23 +0800 |
---|---|---|
committer | piaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2005-06-13 14:51:23 +0800 |
commit | 35813f885d9d155163dbc712179f398e1fe44ea2 (patch) | |
tree | af7ad29d6c366f433910edcd5d5e8588dc03727e /mbbsd | |
parent | 3e281fd6b31e72e83322579e89a0cb9285d960e9 (diff) | |
download | pttbbs-35813f885d9d155163dbc712179f398e1fe44ea2.tar pttbbs-35813f885d9d155163dbc712179f398e1fe44ea2.tar.gz pttbbs-35813f885d9d155163dbc712179f398e1fe44ea2.tar.bz2 pttbbs-35813f885d9d155163dbc712179f398e1fe44ea2.tar.lz pttbbs-35813f885d9d155163dbc712179f398e1fe44ea2.tar.xz pttbbs-35813f885d9d155163dbc712179f398e1fe44ea2.tar.zst pttbbs-35813f885d9d155163dbc712179f398e1fe44ea2.zip |
update board notes behavior
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@2837 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd')
-rw-r--r-- | mbbsd/bbs.c | 13 | ||||
-rw-r--r-- | mbbsd/board.c | 1 | ||||
-rw-r--r-- | mbbsd/var.c | 2 |
3 files changed, 12 insertions, 4 deletions
diff --git a/mbbsd/bbs.c b/mbbsd/bbs.c index 6cf51226..bfd3108c 100644 --- a/mbbsd/bbs.c +++ b/mbbsd/bbs.c @@ -92,7 +92,7 @@ save_violatelaw(void) * void make_blist() { CreateNameList(); apply_boards(g_board_names); } */ -static time4_t *board_note_time; +static time4_t *board_note_time = NULL; void set_board(void) @@ -113,6 +113,15 @@ set_board(void) vmsg("進入未經授權看板"); board_note_time = &bp->bupdate; + /* board_visit_time was broken before. + * It seems like that the behavior should be + * "Show board notes once per login" + * but the real bahavior was + * "Show board everytime I enter board". + * So, let's disable board_visit_time now. + */ + // board_visit_time = getbrdtime(ptr->bid); + if(bp->BM[0] <= ' ') strcpy(currBM, "徵求中"); else @@ -2718,7 +2727,7 @@ Read(void) setutmpmode(READING); set_board(); - if (board_visit_time < *board_note_time) { + if (board_note_time && board_visit_time < *board_note_time) { int mr = 0; setbfile(buf, currboard, fn_notes); diff --git a/mbbsd/board.c b/mbbsd/board.c index 2153d9a3..9f0a7ce2 100644 --- a/mbbsd/board.c +++ b/mbbsd/board.c @@ -1186,7 +1186,6 @@ choose_board(int newflag) head = tmp - t_lines / 2; getkeep(buf, head > 1 ? head : 1, tmp + 1); } - board_visit_time = getbrdtime(ptr->bid); Read(); check_newpost(ptr); head = -1; diff --git a/mbbsd/var.c b/mbbsd/var.c index c9e439ca..8da44567 100644 --- a/mbbsd/var.c +++ b/mbbsd/var.c @@ -369,7 +369,7 @@ char currdirect[64]; char save_title[STRLEN]; /* bbs.c */ -time4_t board_visit_time; +time4_t board_visit_time = 0; char real_name[IDLEN + 1]; char local_article; |