mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-01-09 17:38:00 +00:00
Keepalives are now in seconds not minutes
[originally from svn r874]
This commit is contained in:
parent
20397a174f
commit
72cdcc611a
2
putty.h
2
putty.h
@ -140,7 +140,7 @@ typedef struct {
|
||||
enum { PROT_RAW, PROT_TELNET, PROT_SSH } protocol;
|
||||
int close_on_exit;
|
||||
int warn_on_close;
|
||||
int ping_interval;
|
||||
int ping_interval; /* in seconds */
|
||||
/* SSH options */
|
||||
char remote_cmd[512];
|
||||
int nopty;
|
||||
|
11
settings.c
11
settings.c
@ -44,7 +44,8 @@ void save_settings (char *section, int do_host, Config *cfg) {
|
||||
}
|
||||
write_setting_i (sesskey, "CloseOnExit", !!cfg->close_on_exit);
|
||||
write_setting_i (sesskey, "WarnOnClose", !!cfg->warn_on_close);
|
||||
write_setting_i (sesskey, "PingInterval", cfg->ping_interval);
|
||||
write_setting_i (sesskey, "PingInterval", cfg->ping_interval / 60); /* minutes */
|
||||
write_setting_i (sesskey, "PingIntervalSecs", cfg->ping_interval % 60); /* seconds */
|
||||
write_setting_s (sesskey, "TerminalType", cfg->termtype);
|
||||
write_setting_s (sesskey, "TerminalSpeed", cfg->termspeed);
|
||||
{
|
||||
@ -167,7 +168,13 @@ void load_settings (char *section, int do_host, Config *cfg) {
|
||||
|
||||
gppi (sesskey, "CloseOnExit", 1, &cfg->close_on_exit);
|
||||
gppi (sesskey, "WarnOnClose", 1, &cfg->warn_on_close);
|
||||
gppi (sesskey, "PingInterval", 0, &cfg->ping_interval);
|
||||
{
|
||||
/* This is two values for backward compatibility with 0.50/0.51 */
|
||||
int pingmin, pingsec;
|
||||
gppi (sesskey, "PingInterval", 0, &pingmin);
|
||||
gppi (sesskey, "PingIntervalSecs", 0, &pingsec);
|
||||
cfg->ping_interval = pingmin*60 + pingsec;
|
||||
}
|
||||
gpps (sesskey, "TerminalType", "xterm", cfg->termtype,
|
||||
sizeof(cfg->termtype));
|
||||
gpps (sesskey, "TerminalSpeed", "38400,38400", cfg->termspeed,
|
||||
|
2
windlg.c
2
windlg.c
@ -960,7 +960,7 @@ static int GenericMainDlgProc (HWND hwnd, UINT msg,
|
||||
}
|
||||
beginbox(&cp, "Sending of null packets to keep session active",
|
||||
IDC_BOX_CONNECTION2, IDC_BOXT_CONNECTION2);
|
||||
staticedit(&cp, "Minutes between &keepalives (0 to turn off)",
|
||||
staticedit(&cp, "Seconds between &keepalives (0 to turn off)",
|
||||
IDC_PINGSTATIC, IDC_PINGEDIT, 25);
|
||||
endbox(&cp);
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user