xref: /csrg-svn/usr.bin/telnet/externs.h (revision 33685)
1*33685Sbostic /*
2*33685Sbostic  * Copyright (c) 1988 Regents of the University of California.
3*33685Sbostic  * All rights reserved.
4*33685Sbostic  *
5*33685Sbostic  * Redistribution and use in source and binary forms are permitted
6*33685Sbostic  * provided that this notice is preserved and that due credit is given
7*33685Sbostic  * to the University of California at Berkeley. The name of the University
8*33685Sbostic  * may not be used to endorse or promote products derived from this
9*33685Sbostic  * software without specific prior written permission. This software
10*33685Sbostic  * is provided ``as is'' without express or implied warranty.
11*33685Sbostic  *
12*33685Sbostic  *	@(#)externs.h	1.7 (Berkeley) 03/08/88
13*33685Sbostic  */
14*33685Sbostic 
1532141Sminshall #include <stdio.h>
1632141Sminshall #include <setjmp.h>
1732141Sminshall 
1832141Sminshall #define	SUBBUFSIZE	100
1932141Sminshall 
2032141Sminshall extern int errno;		/* outside this world */
2132141Sminshall 
2232141Sminshall extern int
2332141Sminshall 	flushout,		/* flush output */
2432141Sminshall 	connected,		/* Are we connected to the other side? */
2532141Sminshall 	globalmode,		/* Mode tty should be in */
2632141Sminshall 	In3270,			/* Are we in 3270 mode? */
2732141Sminshall 	telnetport,		/* Are we connected to the telnet port? */
2832141Sminshall 	localchars,		/* we recognize interrupt/quit */
2932141Sminshall 	donelclchars,		/* the user has set "localchars" */
3032141Sminshall 	showoptions,
3132141Sminshall 	net,
3232141Sminshall 	crlf,		/* Should '\r' be mapped to <CR><LF> (or <CR><NUL>)? */
3332141Sminshall 	autoflush,		/* flush output when interrupting? */
3432141Sminshall 	autosynch,		/* send interrupt characters with SYNCH? */
3532531Sminshall 	SYNCHing,		/* Is the stream in telnet SYNCH mode? */
3632141Sminshall 	donebinarytoggle,	/* the user has put us in binary */
3732141Sminshall 	dontlecho,		/* do we suppress local echoing right now? */
3832141Sminshall 	crmod,
3932141Sminshall 	netdata,		/* Print out network data flow */
4032141Sminshall 	debug;			/* Debug level */
4132141Sminshall 
4232141Sminshall extern char
4332141Sminshall 	echoc,			/* Toggle local echoing */
4432141Sminshall 	escape,			/* Escape to command mode */
4532141Sminshall 	doopt[],
4632141Sminshall 	dont[],
4732141Sminshall 	will[],
4832141Sminshall 	wont[],
4932141Sminshall 	hisopts[],
5032141Sminshall 	myopts[],
5132141Sminshall 	*hostname,		/* Who are we connected to? */
5232381Sminshall 	*prompt;		/* Prompt for command. */
5332141Sminshall 
5432141Sminshall extern FILE
5532141Sminshall 	*NetTrace;		/* Where debugging output goes */
5632141Sminshall 
5732141Sminshall extern jmp_buf
5832141Sminshall 	peerdied,
5932141Sminshall 	toplevel;		/* For error conditions. */
6032141Sminshall 
6132141Sminshall extern void
6232141Sminshall 	dosynch(),
6332141Sminshall 	setconnmode(),
6432141Sminshall 	setcommandmode();
6532141Sminshall 
6632141Sminshall extern char
6732141Sminshall     termEofChar,
6832141Sminshall     termEraseChar,
6932141Sminshall     termFlushChar,
7032141Sminshall     termIntChar,
7132141Sminshall     termKillChar,
7232141Sminshall     termLiteralNextChar,
7332141Sminshall     termQuitChar;
7432381Sminshall 
7532381Sminshall /* Ring buffer structures which are shared */
7632381Sminshall 
7732381Sminshall extern Ring
7832381Sminshall 	netoring,
7932381Sminshall 	netiring,
8032381Sminshall 	ttyoring,
8132381Sminshall 	ttyiring;
82