diff options
author | scw <scw@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2005-03-28 11:15:29 +0800 |
---|---|---|
committer | scw <scw@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2005-03-28 11:15:29 +0800 |
commit | 40f06acbb56e7136edd1fc9c5cd050b97715cdd3 (patch) | |
tree | 0dd64d4d20a643afc74bf3a72bf87b9ff3e03fe3 /mbbsd/board.c | |
parent | 794b7f4c7aa213e0e1092cd5860330c3037801c4 (diff) | |
download | pttbbs-40f06acbb56e7136edd1fc9c5cd050b97715cdd3.tar pttbbs-40f06acbb56e7136edd1fc9c5cd050b97715cdd3.tar.gz pttbbs-40f06acbb56e7136edd1fc9c5cd050b97715cdd3.tar.bz2 pttbbs-40f06acbb56e7136edd1fc9c5cd050b97715cdd3.tar.lz pttbbs-40f06acbb56e7136edd1fc9c5cd050b97715cdd3.tar.xz pttbbs-40f06acbb56e7136edd1fc9c5cd050b97715cdd3.tar.zst pttbbs-40f06acbb56e7136edd1fc9c5cd050b97715cdd3.zip |
fix 'a' and 'i' in favorite list.
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@2684 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd/board.c')
-rw-r--r-- | mbbsd/board.c | 22 |
1 files changed, 12 insertions, 10 deletions
diff --git a/mbbsd/board.c b/mbbsd/board.c index 420f3f60..ab7fc4b7 100644 --- a/mbbsd/board.c +++ b/mbbsd/board.c @@ -1085,20 +1085,22 @@ choose_board(int newflag) if (bname[0] && (bid = getbnum(bname)) && HasPerm(getbcache(bid))) { - fav_type_t * ptr = fav_add_board(bid); - - if (ptr == NULL) - vmsg("你的最愛太多了啦 真花心"); - else if (ptr->attr & NBRD_FAV) { // already in fav list + fav_type_t * ptr = getboard(bid); + if (ptr != NULL) { // already in fav list // move curser to item for (num = 0; bid != nbrd[num].bid; ++num); } else { - ptr->attr |= NBRD_FAV; + ptr = fav_add_board(bid); + + if (ptr == NULL) + vmsg("你的最愛太多了啦 真花心"); + else { + ptr->attr |= NBRD_FAV; - if (ch == 'i') { - move_in_current_folder(brdnum, num); - } else { - num = brdnum; + if (ch == 'i') + move_in_current_folder(brdnum, num); + else + num = brdnum; } } } |