diff options
author | ptt <ptt@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2005-02-03 03:28:42 +0800 |
---|---|---|
committer | ptt <ptt@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2005-02-03 03:28:42 +0800 |
commit | 3afc553f95f6c5648bf755e8b0654246b7ef0c89 (patch) | |
tree | 8642faa7f7db43159e2f399fd56661ce25b4c32d /mbbsd | |
parent | ff2326f3e08e75a86cce7f878e0b5f6065090d08 (diff) | |
download | pttbbs-3afc553f95f6c5648bf755e8b0654246b7ef0c89.tar pttbbs-3afc553f95f6c5648bf755e8b0654246b7ef0c89.tar.gz pttbbs-3afc553f95f6c5648bf755e8b0654246b7ef0c89.tar.bz2 pttbbs-3afc553f95f6c5648bf755e8b0654246b7ef0c89.tar.lz pttbbs-3afc553f95f6c5648bf755e8b0654246b7ef0c89.tar.xz pttbbs-3afc553f95f6c5648bf755e8b0654246b7ef0c89.tar.zst pttbbs-3afc553f95f6c5648bf755e8b0654246b7ef0c89.zip |
remove hard coded "PttLaw"./
use attribute bit instead.
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@2454 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd')
-rw-r--r-- | mbbsd/cache.c | 12 |
1 files changed, 6 insertions, 6 deletions
diff --git a/mbbsd/cache.c b/mbbsd/cache.c index 3d703f6c..41f1b22e 100644 --- a/mbbsd/cache.c +++ b/mbbsd/cache.c @@ -708,17 +708,17 @@ haspostperm(char *bname) if (!strcasecmp(bname, DEFAULT_BOARD)) return 1; - if (!strcasecmp(bname, "PttLaw")) - return 1; - - if (!HAS_PERM(PERM_POST)) + if (!(i = getbnum(bname))) return 0; - if (!(i = getbnum(bname))) + if (bcache[i - 1].brdattr & BRD_GUESTPOST) + return 1; + + if (!HAS_PERM(PERM_POST)) return 0; /* 秘密看板特別處理 */ - if (bcache[i - 1].brdattr & (BRD_HIDE | BRD_GUESTPOST)) + if (bcache[i - 1].brdattr & BRD_HIDE) return 1; else if (bcache[i - 1].brdattr & BRD_RESTRICTEDPOST && hbflcheck(i, usernum)) |