summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorpiaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2008-02-21 21:23:57 +0800
committerpiaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2008-02-21 21:23:57 +0800
commitac69927df13fbf63bd7d2113b3eba47fcaf75b18 (patch)
tree0ed620129d93a20f0bb833aa84d0ff256fdaba10
parentd7ddb05467ad91a8b0f7a8be7d4a06b416f2c293 (diff)
downloadpttbbs-ac69927df13fbf63bd7d2113b3eba47fcaf75b18.tar
pttbbs-ac69927df13fbf63bd7d2113b3eba47fcaf75b18.tar.gz
pttbbs-ac69927df13fbf63bd7d2113b3eba47fcaf75b18.tar.bz2
pttbbs-ac69927df13fbf63bd7d2113b3eba47fcaf75b18.tar.lz
pttbbs-ac69927df13fbf63bd7d2113b3eba47fcaf75b18.tar.xz
pttbbs-ac69927df13fbf63bd7d2113b3eba47fcaf75b18.tar.zst
pttbbs-ac69927df13fbf63bd7d2113b3eba47fcaf75b18.zip
- admin: new-regform: fixed: 'q' deletes all forms in last page.
git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@3936 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
-rw-r--r--mbbsd/admin.c17
1 files changed, 12 insertions, 5 deletions
diff --git a/mbbsd/admin.c b/mbbsd/admin.c
index 9914959d..4403fbb3 100644
--- a/mbbsd/admin.c
+++ b/mbbsd/admin.c
@@ -1855,12 +1855,15 @@ handle_register_form(const char *regfile, int dryrun)
ci = cforms -1;
} // while(ch != QUIT/SAVE)
- // quick exit
+ // if exit, we still need to skip all read forms
if (ch == 'q')
- break;
+ {
+ for (i = 0; i < cforms; i++)
+ ans[i] = 's';
+ }
// page complete (save).
- assert(ch == ' ');
+ assert(ch == ' ' || ch == 'q');
// solving blank (undecided entries)
for (i = 0, blanks = 0; i < cforms; i++)
@@ -1905,7 +1908,8 @@ handle_register_form(const char *regfile, int dryrun)
ans[i] == 'n' ? rejects[i] :
ans[i] == 'y' ? justify : "");
}
- pressanykey();
+ if (ch != 'q')
+ pressanykey();
}
else
{
@@ -2002,12 +2006,15 @@ m_register(void)
#ifdef EXP_ADMIN_REGFORM
else if (ans[0] == 'e')
{
+#ifdef EXP_ADMIN_REGFORM_DRYRUN
clear();
outs("瞷璶秈琌龟喷┦穝ㄑ代刚ノ\n"
"叫猔種: 单ち糵埃单单笆常琌安ぃ穦痷糶╰参");
pressanykey();
-
handle_register_form(fn_register, 1);
+#else
+ handle_register_form(fn_register, 0);
+#endif
}
#endif