diff options
author | ptt <ptt@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2002-06-23 09:56:13 +0800 |
---|---|---|
committer | ptt <ptt@63ad8ddf-47c3-0310-b6dd-a9e9d9715204> | 2002-06-23 09:56:13 +0800 |
commit | 8614f184ddcfa2ab610a3c40ec96b23a78080abd (patch) | |
tree | 12cc8cfd798d69f73818cdf057f6f2a5fb0a7f87 | |
parent | 1cdf318f40969ef8df3f2671f9a338951e644cd9 (diff) | |
download | pttbbs-8614f184ddcfa2ab610a3c40ec96b23a78080abd.tar pttbbs-8614f184ddcfa2ab610a3c40ec96b23a78080abd.tar.gz pttbbs-8614f184ddcfa2ab610a3c40ec96b23a78080abd.tar.bz2 pttbbs-8614f184ddcfa2ab610a3c40ec96b23a78080abd.tar.lz pttbbs-8614f184ddcfa2ab610a3c40ec96b23a78080abd.tar.xz pttbbs-8614f184ddcfa2ab610a3c40ec96b23a78080abd.tar.zst pttbbs-8614f184ddcfa2ab610a3c40ec96b23a78080abd.zip |
fix gamble lock
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk/pttbbs@338 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r-- | mbbsd/admin.c | 20 |
1 files changed, 13 insertions, 7 deletions
diff --git a/mbbsd/admin.c b/mbbsd/admin.c index 19f56d40..f31ee516 100644 --- a/mbbsd/admin.c +++ b/mbbsd/admin.c @@ -1,4 +1,4 @@ -/* $Id: admin.c,v 1.23 2002/06/19 13:21:59 lwms Exp $ */ +/* $Id: admin.c,v 1.24 2002/06/23 01:56:13 ptt Exp $ */ #include "bbs.h" /* 使用者管理 */ @@ -204,19 +204,25 @@ int m_mod_board(char *bname) { /* Ptt 這邊斷行會檔到下面 */ move(9, 0); - sprintf(genbuf, "看板 (E)設定 (V)違法/解除 %s (D)刪除 [Q]取消?", + sprintf(genbuf, "(E)設定 (V)違法/解除 %s (D)刪除 [Q]取消?", HAS_PERM(PERM_SYSOP) ? - " (B)BVote (S)救回文章" : ""); + " (B)BVote (S)救回文章 (G)賭盤解卡" : ""); getdata(10, 0, genbuf, ans, sizeof(ans), LCECHO); switch(*ans) { + case 'g': + if(HAS_PERM(PERM_SYSOP) ) { + char path[256]; + setbfile(genbuf,bname,FN_TICKET_LOCK); + setbfile(path,bname,FN_TICKET_END); + rename(genbuf,path); + } + break; case 's': if(HAS_PERM(PERM_SYSOP) ) { - char actionbuf[512]; - - sprintf(actionbuf, BBSHOME "/bin/buildir boards/%c/%s &", + sprintf(genbuf, BBSHOME "/bin/buildir boards/%c/%s &", bh.brdname[0], bh.brdname); - system(actionbuf); + system(genbuf); } break; case 'b': |