mirror of
https://git.tartarus.org/simon/putty.git
synced 2025-01-09 17:38:00 +00:00
settings.c: Don't ignore boolean settings
Revision1b2f39c24b
introduced guards to use the built-in defaults in the event that the SESSKEY was null. This was later reverted in39c20d4819
because (a) a null SESSKEY is precisely how the absence of a per-session configuration file is signalled to the backend, and (b) everything could apparently already cope with a null SESSKEY anyway. Unfortunately, in between these,3214563d8e
introduced new functions for handling boolean-valued settings. The reversion didn't affect the new `gppb_raw' function, which retained the erroneous guard against null SESSKEY. In consequence, PuTTY ignores X resources and `-xrm' settings unless `~/.putty/sessions/Default%20Settings' exists, causing undesirable behaviour such as starting login shells, establishing `utmp' entries, scrolling on output, failing to scroll on keypress, not blinking the cursor, etc. This isn't a total disaster: touching `~/.putty/sessions/Default%20Settings' makes the problem go away. But it seems worth fixing anyway. Apply the obvious one-line fix. Signed-off-by: Mark Wooding <mdw@distorted.org.uk>
This commit is contained in:
parent
a5bcf3d384
commit
400c895ced
@ -168,7 +168,7 @@ static void gppfile(settings_r *sesskey, const char *name,
|
||||
static bool gppb_raw(settings_r *sesskey, const char *name, bool def)
|
||||
{
|
||||
def = platform_default_b(name, def);
|
||||
return sesskey ? read_setting_i(sesskey, name, def) != 0 : def;
|
||||
return read_setting_i(sesskey, name, def) != 0;
|
||||
}
|
||||
|
||||
static void gppb(settings_r *sesskey, const char *name, bool def,
|
||||
|
Loading…
Reference in New Issue
Block a user