1
0
mirror of https://git.tartarus.org/simon/putty.git synced 2025-06-30 19:12:48 -05:00

Implement Simon's suggestion of moving DEFAULT_PROTOCOL into a per-backend-

link-module const variable `be_default_protocol' which suggests a sensible
default to the front end (which can ignore it). (DEFAULT_PORT is replaced by a
lookup in the backend[] table.)
Still not pretty, but it does mean that the recent fix for `ssh-default'
doesn't break PuTTYtel.

[originally from svn r2613]
This commit is contained in:
Jacob Nevins
2003-01-15 20:47:50 +00:00
parent c6920b01c4
commit e8ebb4c879
5 changed files with 37 additions and 17 deletions

18
putty.h
View File

@ -217,6 +217,12 @@ extern struct backend_list {
Backend *backend;
} backends[];
/*
* Suggested default protocol provided by the backend link module.
* The application is free to ignore this.
*/
extern const int be_default_protocol;
struct config_tag {
/* Basic options */
char host[512];
@ -370,18 +376,6 @@ struct config_tag {
int shadowboldoffset;
};
/*
* You can compile with -DTELNET_DEFAULT to have telnet by default
* (otherwise SSH is the default).
*/
#ifdef TELNET_DEFAULT
#define DEFAULT_PROTOCOL PROT_TELNET
#define DEFAULT_PORT 23
#else
#define DEFAULT_PROTOCOL PROT_SSH
#define DEFAULT_PORT 22
#endif
/*
* Some global flags denoting the type of application.
*