summaryrefslogtreecommitdiffstats
path: root/mbbsd/vote.c
diff options
context:
space:
mode:
authorpiaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2009-09-14 01:13:33 +0800
committerpiaip <piaip@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2009-09-14 01:13:33 +0800
commit9bb2b461450f6b953032aac4e57238cdff4e296a (patch)
treed102bbf927737bf989f5916c7c26f3d178734a1c /mbbsd/vote.c
parent05dd93de8f37b2fcb2c7ed26c0cb18e550678494 (diff)
downloadpttbbs-9bb2b461450f6b953032aac4e57238cdff4e296a.tar
pttbbs-9bb2b461450f6b953032aac4e57238cdff4e296a.tar.gz
pttbbs-9bb2b461450f6b953032aac4e57238cdff4e296a.tar.bz2
pttbbs-9bb2b461450f6b953032aac4e57238cdff4e296a.tar.lz
pttbbs-9bb2b461450f6b953032aac4e57238cdff4e296a.tar.xz
pttbbs-9bb2b461450f6b953032aac4e57238cdff4e296a.tar.zst
pttbbs-9bb2b461450f6b953032aac4e57238cdff4e296a.zip
* put-back the code to handle numlogin (changed to numlogindays)
* we can enable this after current code base becomes stable git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@4838 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd/vote.c')
-rw-r--r--mbbsd/vote.c11
1 files changed, 8 insertions, 3 deletions
diff --git a/mbbsd/vote.c b/mbbsd/vote.c
index 030c6704..b54cd6b1 100644
--- a/mbbsd/vote.c
+++ b/mbbsd/vote.c
@@ -646,9 +646,14 @@ vote_maintain(const char *bname)
closetime = atoi(inbuf); // borrow variable
} while (closetime < 0 || closetime > 120);
fprintf(fp, "%d\n", now - (MONTH_SECONDS * closetime));
-
- fprintf(fp, "%d\n", 0); // was: numlogins
-
+ closetime = 0;
+#ifdef USE_LOGIN_LIMITS
+ do {
+ getdata(6, 0, STR_LOGINDAYS "¤U­­", inbuf, 6, DOECHO);
+ closetime = atoi(inbuf); // borrow variable
+ } while (closetime < 0);
+#endif
+ fprintf(fp, "%d\n", closetime);
do {
getdata(6, 0, "¤å³¹½g¼Æ¤U­­", inbuf, 6, DOECHO);
closetime = atoi(inbuf); // borrow variable