Commit | Line | Data |
---|---|---|
ad54d2e3 GM |
1 | #include <stdio.h> |
2 | #include <setjmp.h> | |
3 | ||
4 | #define SUBBUFSIZE 100 | |
5 | ||
6 | extern int errno; /* outside this world */ | |
7 | ||
8 | extern int | |
ad54d2e3 GM |
9 | flushout, /* flush output */ |
10 | connected, /* Are we connected to the other side? */ | |
11 | globalmode, /* Mode tty should be in */ | |
12 | In3270, /* Are we in 3270 mode? */ | |
13 | telnetport, /* Are we connected to the telnet port? */ | |
14 | localchars, /* we recognize interrupt/quit */ | |
15 | donelclchars, /* the user has set "localchars" */ | |
16 | showoptions, | |
ad54d2e3 GM |
17 | net, |
18 | tin, | |
19 | tout, | |
20 | crlf, /* Should '\r' be mapped to <CR><LF> (or <CR><NUL>)? */ | |
21 | autoflush, /* flush output when interrupting? */ | |
22 | autosynch, /* send interrupt characters with SYNCH? */ | |
23 | donebinarytoggle, /* the user has put us in binary */ | |
24 | dontlecho, /* do we suppress local echoing right now? */ | |
25 | crmod, | |
26 | netdata, /* Print out network data flow */ | |
27 | debug; /* Debug level */ | |
28 | ||
29 | extern char | |
30 | echoc, /* Toggle local echoing */ | |
31 | escape, /* Escape to command mode */ | |
32 | doopt[], | |
33 | dont[], | |
34 | will[], | |
35 | wont[], | |
36 | hisopts[], | |
37 | myopts[], | |
38 | subbuffer[SUBBUFSIZE], | |
39 | *hostname, /* Who are we connected to? */ | |
40 | *prompt, /* Prompt for command. */ | |
41 | *nfrontp, | |
42 | *nbackp, | |
43 | netobuf[2*BUFSIZ], | |
44 | ttyobuf[2*BUFSIZ], | |
45 | *tfrontp, | |
46 | *tbackp; | |
47 | ||
48 | extern FILE | |
49 | *NetTrace; /* Where debugging output goes */ | |
50 | ||
51 | extern jmp_buf | |
52 | peerdied, | |
53 | toplevel; /* For error conditions. */ | |
54 | ||
55 | extern void | |
56 | intr(), | |
57 | intr2(), | |
58 | deadpeer(), | |
59 | dosynch(), | |
60 | doflush(), | |
61 | setconnmode(), | |
62 | setcommandmode(); | |
63 | ||
64 | extern char | |
65 | termEofChar, | |
66 | termEraseChar, | |
67 | termFlushChar, | |
68 | termIntChar, | |
69 | termKillChar, | |
70 | termLiteralNextChar, | |
71 | termQuitChar; |