summaryrefslogtreecommitdiffstats
path: root/mbbsd/chat.c
diff options
context:
space:
mode:
authorptt <ptt@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2002-05-13 11:20:04 +0800
committerptt <ptt@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2002-05-13 11:20:04 +0800
commit6a428fb60d8ec6092d428b2e0f869a31f4890dc7 (patch)
treea0671ea2dc0168a9cb5625f867d553f6d0441efc /mbbsd/chat.c
parent438c456b95eec0e5ac662ca3cf2386dff2c44bc7 (diff)
downloadpttbbs-6a428fb60d8ec6092d428b2e0f869a31f4890dc7.tar
pttbbs-6a428fb60d8ec6092d428b2e0f869a31f4890dc7.tar.gz
pttbbs-6a428fb60d8ec6092d428b2e0f869a31f4890dc7.tar.bz2
pttbbs-6a428fb60d8ec6092d428b2e0f869a31f4890dc7.tar.lz
pttbbs-6a428fb60d8ec6092d428b2e0f869a31f4890dc7.tar.xz
pttbbs-6a428fb60d8ec6092d428b2e0f869a31f4890dc7.tar.zst
pttbbs-6a428fb60d8ec6092d428b2e0f869a31f4890dc7.zip
replace time(NULL) by now
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk/pttbbs@163 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd/chat.c')
-rw-r--r--mbbsd/chat.c7
1 files changed, 3 insertions, 4 deletions
diff --git a/mbbsd/chat.c b/mbbsd/chat.c
index 4825379b..e7e7846a 100644
--- a/mbbsd/chat.c
+++ b/mbbsd/chat.c
@@ -1,4 +1,4 @@
-/* $Id: chat.c,v 1.2 2002/04/28 19:35:28 in2 Exp $ */
+/* $Id: chat.c,v 1.3 2002/05/13 03:20:04 ptt Exp $ */
#include <stdio.h>
#include <stdlib.h>
#include <string.h>
@@ -20,6 +20,7 @@ extern userinfo_t *currutmp;
static int chatline;
static int stop_line; /* next line of bottom of message window area */
static FILE *flog;
+extern time_t now;
static void printchatline(char *str) {
move(chatline, 0);
@@ -192,11 +193,9 @@ static void chat_help(char *arg) {
}
static void chat_date() {
- time_t thetime;
char genbuf[200];
- time(&thetime);
- sprintf(genbuf, "◆ " BBSNAME "標準時間: %s", Cdate(&thetime));
+ sprintf(genbuf, "◆ " BBSNAME "標準時間: %s", Cdate(&now));
printchatline(genbuf);
}