1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-07-01 03:22:48 -05:00

Turned the old `Telnet Command' System-submenu into a more general

`Special Command' menu, in which any backend can place its own list
of magical things the user might want to ask the backend to do. In
particular I've implemented the recently proposed "break" extension
in SSH2 using this mechanism.
NB this checkin slightly breaks the Mac build, since it needs to
provide at least a stub form of update_specials_menu().

[originally from svn r3054]
This commit is contained in:
Simon Tatham
2003-04-04 20:21:05 +00:00
parent e322770ab5
commit 3bd0415579
10 changed files with 184 additions and 89 deletions

View File

@ -955,6 +955,29 @@ static void telnet_special(void *handle, Telnet_Special code)
}
}
static const struct telnet_special *telnet_get_specials(void *handle)
{
static const struct telnet_special specials[] = {
{"Are You There", TS_AYT},
{"Break", TS_BRK},
{"Synch", TS_SYNCH},
{"Erase Character", TS_EC},
{"Erase Line", TS_EL},
{"Go Ahead", TS_GA},
{"No Operation", TS_NOP},
{"", 0},
{"Abort Process", TS_ABORT},
{"Abort Output", TS_AO},
{"Interrupt Process", TS_IP},
{"Suspend Process", TS_SUSP},
{"", 0},
{"End Of Record", TS_EOR},
{"End Of File", TS_EOF},
{NULL, 0}
};
return specials;
}
static Socket telnet_socket(void *handle)
{
Telnet telnet = (Telnet) handle;
@ -1012,6 +1035,7 @@ Backend telnet_backend = {
telnet_sendbuffer,
telnet_size,
telnet_special,
telnet_get_specials,
telnet_socket,
telnet_exitcode,
telnet_sendok,