summaryrefslogtreecommitdiffstats
path: root/mbbsd/chat.c
diff options
context:
space:
mode:
authorin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2002-06-04 21:08:35 +0800
committerin2 <in2@63ad8ddf-47c3-0310-b6dd-a9e9d9715204>2002-06-04 21:08:35 +0800
commit9e81baf8352b3d525c9a1459f28dae6b540988e3 (patch)
treea558e73187b9d45b59280a79c927e7f8bb315623 /mbbsd/chat.c
parente42291049072cfee02408394850b33b3580dbd83 (diff)
downloadpttbbs-9e81baf8352b3d525c9a1459f28dae6b540988e3.tar
pttbbs-9e81baf8352b3d525c9a1459f28dae6b540988e3.tar.gz
pttbbs-9e81baf8352b3d525c9a1459f28dae6b540988e3.tar.bz2
pttbbs-9e81baf8352b3d525c9a1459f28dae6b540988e3.tar.lz
pttbbs-9e81baf8352b3d525c9a1459f28dae6b540988e3.tar.xz
pttbbs-9e81baf8352b3d525c9a1459f28dae6b540988e3.tar.zst
pttbbs-9e81baf8352b3d525c9a1459f28dae6b540988e3.zip
global variable move to var.c
git-svn-id: http://opensvn.csie.org/pttbbs/pttbbs/trunk/pttbbs@280 63ad8ddf-47c3-0310-b6dd-a9e9d9715204
Diffstat (limited to 'mbbsd/chat.c')
-rw-r--r--mbbsd/chat.c47
1 files changed, 4 insertions, 43 deletions
diff --git a/mbbsd/chat.c b/mbbsd/chat.c
index 284403a8..17e004b0 100644
--- a/mbbsd/chat.c
+++ b/mbbsd/chat.c
@@ -1,27 +1,8 @@
-/* $Id: chat.c,v 1.4 2002/05/25 11:18:11 ptt Exp $ */
-#include <stdio.h>
-#include <stdlib.h>
-#include <string.h>
-#include <time.h>
-#include <ctype.h>
-#include <netdb.h>
-#include <unistd.h>
-#include <sys/types.h>
-#include <sys/socket.h>
-#include <netinet/in.h>
-#include "config.h"
-#include "pttstruct.h"
-#include "perm.h"
-#include "common.h"
-#include "modes.h"
-#include "proto.h"
-
-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;
+/* $Id: chat.c,v 1.5 2002/06/04 13:08:33 in2 Exp $ */
+#include "bbs.h"
+static int chatline, stop_line;
+static FILE *flog;
static void printchatline(char *str) {
move(chatline, 0);
if(*str == '>' && !PERM_HIDE(currutmp))
@@ -40,8 +21,6 @@ static void printchatline(char *str) {
fprintf(flog, "%s\n", str);
}
-extern int b_lines; /* Screen bottom line number: t_lines-1 */
-
static void chat_clear() {
for(chatline = 2; chatline < stop_line; chatline++) {
move(chatline, 0);
@@ -125,8 +104,6 @@ static int chat_recv(int fd, char *chatid) {
return 0;
}
-extern userec_t cuser;
-
static int printuserent(userinfo_t *uentp) {
static char uline[80];
static int cnt;
@@ -208,11 +185,6 @@ static void chat_pager() {
printchatline(genbuf);
}
-extern char *str_space;
-extern userec_t xuser;
-extern char *fn_plans;
-extern char *err_uid;
-
static void chat_query(char *arg) {
char *uid;
int tuid;
@@ -245,8 +217,6 @@ static void chat_query(char *arg) {
printchatline(err_uid);
}
-extern char *msg_shortulist;
-
static void chat_users() {
printchatline("");
printchatline("【 " BBSNAME "的遊客列表 】");
@@ -294,8 +264,6 @@ static int chat_cmd(char *buf, int fd) {
return 0;
}
-extern char trans_buffer[256]; /* 一般傳遞變數 add by Ptt */
-
#if 0
static char *select_address() {
int c;
@@ -330,9 +298,6 @@ static char *select_address() {
}
#endif
-extern int usernum;
-extern int t_lines;
-extern char *msg_seperator;
#define MAXLASTCMD 6
static int chatid_len = 10;
@@ -563,7 +528,6 @@ int t_chat() {
continue;
}
if(ch == Ctrl('I')) {
- extern screenline_t *big_picture;
screenline_t *screen0 = calloc(t_lines, sizeof(screenline_t));
memcpy(screen0, big_picture, t_lines * sizeof(screenline_t));
@@ -615,7 +579,4 @@ int t_chat() {
/* -------------------------------------------------- */
#if 0
-extern char page_requestor[];
-extern userinfo_t *currutmp;
-
#endif