RCS file: D:\ythtcvs\bbs\nju09\BBSLIB.c,v
retrieving revision 1.3
retrieving revision 1.4
diff -u -r1.3 -r1.4
--- BBSLIB.c 2005/00/05 04:18:58 1.3
+++ BBSLIB.c 2005/00/09 07:14:29 1.4
@@ -1777,8 +1777,15 @@
return 0;
if (!strcasecmp(x->header.filename, DEFAULTBOARD))
return 1;
- if (user_perm(user, PERM_SYSOP))
- return 1;
+ if (user_perm(user, PERM_SYSOP)) {
+ /*if (x->header.flag & CLUB_FLAG) {
+ sprintf(buf3, "boards/%s/club_users", x->header.filename
);
+ if (!(file_has_word(buf3, user->userid)))
+ return 3; //非俱乐部成员的sysop权限返回3
+ }
+ else*/
+ return 1;
+ }
if (!user_perm(user, PERM_BASIC))
return 0;
if (!user_perm(user, PERM_POST))
@@ -1795,7 +1802,7 @@
if (file_has_word(buf3, user->userid))
return 1;
else
- return 0;
+ return 2; //非俱乐部成员返回2,modified by tnds
}
return 1;
}
===================================================================
RCS file: D:\ythtcvs\bbs\nju09\bbspst.c,v
retrieving revision 1.2
retrieving revision 1.3
diff -u -r1.2 -r1.3
--- bbspst.c 2005/00/04 14:47:19 1.2
+++ bbspst.c 2005/00/09 07:14:28 1.3
@@ -6,6 +6,8 @@
int local_article, num, fullquote = 0, guestre = 0, thread = -1;
char *ptr, userid[80], buf[512], path[512], file[512], board[512],
title[80] = "";
+ int club;
+ char temp[70];
struct fileheader *dirinfo = NULL;
struct boardmem *x;
struct mmapfile mf = { ptr:NULL };
@@ -40,8 +42,14 @@
http_fatal("错误的讨论区或者您无权在此讨论区发表文章");
if (njuinn_board(board) && !innd_board(board))
local_article = 1;
- if (!has_post_perm(currentuser, x) && !isguest)
- http_fatal("错误的讨论区或者您无权在此讨论区发表文章");
+ club=has_post_perm(currentuser,x);
+ if (club==2) {
+ sprintf(temp,"%s为俱乐部版面,而您不是%s俱乐部的成员,请向%s俱乐
部的版务申请发文权限",board,board,board);
+ http_fatal(temp);
+ } else {
+ if (club!=1 && !isguest)
+ http_fatal("错误的讨论区或者您无权在此讨论区发表文章");
+ }
if (noadm4political(board))
http_fatal("对不起,因为没有版面管理人员在线,本版暂时封闭.");
if (x->ban == 2)