X-Git-Url: https://git.distorted.org.uk/u/mdw/putty/blobdiff_plain/4044fc45ca4a742c0ff29a49faca7cc9db99b251..98f59a35ab7c529243c5dfd76af72a8d6e73729d:/putty.h diff --git a/putty.h b/putty.h index 28320de0..da1fb870 100644 --- a/putty.h +++ b/putty.h @@ -189,6 +189,7 @@ enum { struct backend_tag { char *(*init) (void *frontend_handle, void **backend_handle, Config *cfg, char *host, int port, char **realhost, int nodelay); + void (*free) (void *handle); /* back->reconfig() passes in a replacement configuration. */ void (*reconfig) (void *handle, Config *cfg); /* back->send() returns the current amount of buffered data. */ @@ -217,6 +218,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]; @@ -371,18 +378,6 @@ struct config_tag { }; /* - * 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. * * FLAG_VERBOSE is set when the user requests verbose details. @@ -479,6 +474,7 @@ void random_destroy_seed(void); * Exports from settings.c. */ void save_settings(char *section, int do_host, Config * cfg); +void save_open_settings(void *sesskey, int do_host, Config *cfg); void load_settings(char *section, int do_host, Config * cfg); void load_open_settings(void *sesskey, int do_host, Config *cfg); void get_sesslist(struct sesslist *, int allocate); @@ -502,6 +498,7 @@ int platform_default_i(const char *name, int def); */ Terminal *term_init(Config *, struct unicode_data *, void *); +void term_free(Terminal *); void term_size(Terminal *, int, int, int); void term_out(Terminal *); void term_paint(Terminal *, Context, int, int, int, int, int); @@ -531,6 +528,7 @@ void term_provide_logctx(Terminal *term, void *logctx); * Exports from logging.c. */ void *log_init(void *frontend, Config *cfg); +void log_free(void *logctx); void log_reconfig(void *logctx, Config *cfg); void logfopen(void *logctx); void logfclose(void *logctx); @@ -580,6 +578,7 @@ extern Backend ssh_backend; * Exports from ldisc.c. */ void *ldisc_create(Config *, Terminal *, Backend *, void *, void *); +void ldisc_free(void *); void ldisc_send(void *handle, char *buf, int len, int interactive); /*