summaryrefslogtreecommitdiffstats
path: root/mbbsd/vice.c
diff options
context:
space:
mode:
authorkcwu <kcwu@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2004-06-10 15:08:55 +0800
committerkcwu <kcwu@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2004-06-10 15:08:55 +0800
commit7844305800a7a4781ac46777d429dbe667327911 (patch)
tree28e429be86f0ecc20cb7d30d95d054b420f09bc9 /mbbsd/vice.c
parent3b109adbea257408835589c45e0125f77064274c (diff)
downloadpttbbs-7844305800a7a4781ac46777d429dbe667327911.tar
pttbbs-7844305800a7a4781ac46777d429dbe667327911.tar.gz
pttbbs-7844305800a7a4781ac46777d429dbe667327911.tar.bz2
pttbbs-7844305800a7a4781ac46777d429dbe667327911.tar.lz
pttbbs-7844305800a7a4781ac46777d429dbe667327911.tar.xz
pttbbs-7844305800a7a4781ac46777d429dbe667327911.tar.zst
pttbbs-7844305800a7a4781ac46777d429dbe667327911.zip
replace some prints() with outs(),
replace some outs() with outc(), replace some fprintf() with fputs(), and so on. for performance. and don't treat user input as format string. git-svn-id: http://opensvn.csie.org/pttbbs/trunk/pttbbs@2055 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd/vice.c')
-rw-r--r--mbbsd/vice.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/mbbsd/vice.c b/mbbsd/vice.c
index e774479c..fc8e9044 100644
--- a/mbbsd/vice.c
+++ b/mbbsd/vice.c
@@ -1,4 +1,4 @@
-/* $Id: vice.c,v 1.9 2003/06/28 08:49:26 kcwu Exp $ */
+/* $Id$ */
#include "bbs.h"
#define VICE_PLAY BBSHOME "/etc/vice/vice.play"
@@ -63,7 +63,7 @@ ran_showfile(int y, int x, char *filename, int maxnum)
move(y, x);
while (fgets(buf, sizeof(buf), fs))
- prints("%s", buf);
+ outs(buf);
fclose(fs);
return 1;
@@ -106,7 +106,7 @@ vice_main()
i = 0;
move(10, 24);
clrtoeol();
- prints("這一期的發票號碼");
+ outs("這一期的發票號碼");
while (fgets(serial, 15, fd)) {
if ((ptr = strchr(serial, '\r')))
*ptr = 0;
@@ -115,7 +115,7 @@ vice_main()
if( i >= 14 )
break;
move(10 + i, 24 + j);
- prints("%s", serial);
+ outs(serial);
j += 9;
j %= 45;
}