diff options
Diffstat (limited to 'mbbsd')
-rw-r--r-- | mbbsd/cal.c | 7 | ||||
-rw-r--r-- | mbbsd/user.c | 10 | ||||
-rw-r--r-- | mbbsd/voteboard.c | 19 |
3 files changed, 14 insertions, 22 deletions
diff --git a/mbbsd/cal.c b/mbbsd/cal.c index 4082de51..ee39fd83 100644 --- a/mbbsd/cal.c +++ b/mbbsd/cal.c @@ -291,11 +291,12 @@ p_from(void) reload_money(); if (cuser.money < 49) return 0; - if (getdata_buf(b_lines - 1, 0, "�п�J�s�G�m:", - tmp_from, sizeof(tmp_from), DOECHO)) { + if (getdata(b_lines - 1, 0, "�п�J�s�G�m:", + tmp_from, sizeof(tmp_from), DOECHO) && + strcmp(tmp_from, currutmp->from) != 0) + { vice(49, "���G�m"); strlcpy(currutmp->from, tmp_from, sizeof(currutmp->from)); - currutmp->from_alias = 0; } return 0; } diff --git a/mbbsd/user.c b/mbbsd/user.c index 4640c60d..10b9f6c8 100644 --- a/mbbsd/user.c +++ b/mbbsd/user.c @@ -127,7 +127,7 @@ user_display(const userec_t * u, int adminmode) " " ANSI_COLOR(30;41) "�r�s�r�s�r�s" ANSI_RESET " " ANSI_COLOR(1;30;45) " �� �� ��" " �� �� " " " ANSI_RESET " " ANSI_COLOR(30;41) "�r�s�r�s�r�s" ANSI_RESET "\n"); - prints("\t\t�N���ʺ�: %s(%s)\n", u->userid, u->nickname); + prints("\t\t�N���ʺ�: %s (%s)\n", u->userid, u->nickname); prints("\t\t�u��m�W: %s", u->realname); #if FOREIGN_REG_DAY > 0 prints(" %s%s", @@ -153,10 +153,10 @@ user_display(const userec_t * u, int adminmode) u->year + 1900, u->month, u->day, resolve_over18_user(u) ? "�w" : "��"); - prints("\t\t���U���: %s (�w��%d��)\n", + prints("\t\t���U���: %s (�w�� %d ��)\n", Cdate(&u->firstlogin), (int)((now - u->firstlogin)/DAY_SECONDS)); - prints("\t\t�W���W��: %s (%s)\n", - u->lasthost, Cdate(&u->lastlogin)); + prints("\t\t�W���W��: %s (�Ӧ� %s)\n", + Cdate(&u->lastlogin), u->lasthost); if (adminmode) { strcpy(genbuf, "bTCPRp#@XWBA#VSM0123456789ABCDEF"); @@ -167,7 +167,7 @@ user_display(const userec_t * u, int adminmode) prints("\t\t�{�Ҹ��: %s\n", u->justify); } - prints("\t\t�W���峹: %d �� / %d �g\n", + prints("\t\t�W���峹: �W�� %d �� / �峹 %d �g\n", u->numlogins, u->numposts); sethomedir(genbuf, u->userid); diff --git a/mbbsd/voteboard.c b/mbbsd/voteboard.c index 84fea5fa..f9af60ff 100644 --- a/mbbsd/voteboard.c +++ b/mbbsd/voteboard.c @@ -59,14 +59,12 @@ do_voteboardreply(const fileheader_t * fhdr) clear(); if (!CheckPostPerm()||HasUserPerm(PERM_NOCITIZEN)) { - move(5, 10); vmsg("�藍�_�A�z�ثe�L�k�b���o���峹�I"); return; } if (!CheckVoteRestrictionFile(fhdr)) { - move(5, 10); // why move (5, 10)? vmsg("�A������`��I (�i�� i �d�ݭ���)"); return; } @@ -201,25 +199,18 @@ do_voteboard(int type) FILE *fp; int temp; - clear(); if (!CheckPostPerm()) { - move(5, 10); vmsg("�藍�_�A�z�ثe�L�k�b���o���峹�I"); return FULLUPDATE; } if (!CheckVoteRestriction(currbid)) { - move(5, 10); // why move (5, 10)? vmsg("�A������`��I (�i�� i �d�ݭ���)"); return FULLUPDATE; } - move(0, 0); - clrtobot(); - outs("�z���b�ϥ�" BBSNAME "���s�p�t��\n"); - outs("���s�p�t�αN�߰ݱz�@�ǰ��D�A�Фp�ߦ^���~��}�l�s�p\n"); - outs("���N���X�s�p�ת̡A�N�Q�C�J�����w��ϥΪ̳�\n"); - move(4, 0); - clrtobot(); + vs_hdr(BBSNAME "�s�p�t��"); + outs("�z���b�ϥ�" BBSNAME "���s�p�t�ΡA�Фp�ߦ^���U�C���D�~��}�l�s�p\n"); + outs("���N���X�s�p�ת̡A�N�Q�C�J�����w��ϥΪ̳�\n\n"); outs("(1)���ʳs�p (2)�O�W���� "); if(type==0) outs("(3)�ӽзs�O (4)�o���ªO (5)�s�p�O�D \n(6)�}�K�O�D (7)�s�p�p�ժ� (8)�}�K�p�ժ� (9)�ӽзs�s��\n"); @@ -390,8 +381,8 @@ do_voteboard(int type) /* use lower 16 bits of 'money' to store limits */ /* lower 8 bits are posts, higher 8 bits are logins */ votefile.multi.vote_limits.regtime = bcache[currbid - 1].vote_limit_regtime; - votefile.multi.vote_limits.logins = bcache[currbid - 1].vote_limit_logins; - votefile.multi.vote_limits.posts = bcache[currbid - 1].vote_limit_posts; + votefile.multi.vote_limits.logins = bcache[currbid - 1].vote_limit_logins; + votefile.multi.vote_limits.posts = bcache[currbid - 1].vote_limit_posts; votefile.multi.vote_limits.badpost = bcache[currbid - 1].vote_limit_badpost; setbdir(genbuf, currboard); if (append_record(genbuf, &votefile, sizeof(votefile)) != -1) |