summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorkcwu <kcwu@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2003-01-17 15:08:04 +0800
committerkcwu <kcwu@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2003-01-17 15:08:04 +0800
commit56559dcfe5456a46ed8f017c30ae4b703f75c6c7 (patch)
tree0c63a7ebbbecbe1cae7ef6b8d7dee1152a5f2583
parentcab9d16f21db67973564c64acf1c56f6c3848f5c (diff)
downloadpttbbs-56559dcfe5456a46ed8f017c30ae4b703f75c6c7.tar
pttbbs-56559dcfe5456a46ed8f017c30ae4b703f75c6c7.tar.gz
pttbbs-56559dcfe5456a46ed8f017c30ae4b703f75c6c7.tar.bz2
pttbbs-56559dcfe5456a46ed8f017c30ae4b703f75c6c7.tar.lz
pttbbs-56559dcfe5456a46ed8f017c30ae4b703f75c6c7.tar.xz
pttbbs-56559dcfe5456a46ed8f017c30ae4b703f75c6c7.tar.zst
pttbbs-56559dcfe5456a46ed8f017c30ae4b703f75c6c7.zip
fix bug: access bache[-2] if sysop enter hot-board-list and hit 'f'
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk/pttbbs@616 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r--mbbsd/board.c5
1 files changed, 3 insertions, 2 deletions
diff --git a/mbbsd/board.c b/mbbsd/board.c
index 98b88b87..4d5a42dc 100644
--- a/mbbsd/board.c
+++ b/mbbsd/board.c
@@ -1,4 +1,4 @@
-/* $Id: board.c,v 1.68 2003/01/16 11:58:04 kcwu Exp $ */
+/* $Id: board.c,v 1.69 2003/01/17 07:08:04 kcwu Exp $ */
#include "bbs.h"
#define BRC_STRLEN 15 /* Length of board name */
#define BRC_MAXSIZE 24576
@@ -48,6 +48,7 @@ static char brc_buf[BRC_MAXSIZE];
static char brc_name[BRC_STRLEN];
static char *fn_boardrc = ".boardrc";
static int brc_size;
+char *brc_buf_addr=brc_buf;
void
brc_update()
@@ -927,7 +928,7 @@ choose_board(int newflag)
break;
case 'F':
case 'f':
- if (class_bid && HAS_PERM(PERM_SYSOP)) {
+ if (class_bid>0 && HAS_PERM(PERM_SYSOP)) {
bcache[class_bid - 1].firstchild[cuser.uflag & BRDSORT_FLAG ? 1 : 0]
= NULL;
brdnum = -1;