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

Avoid launching a session from the Default Settings, even if they do

represent a launchable session, unless the user can be construed to
have really meant it. This means:
 - starting up PuTTY when the Default Settings are launchable still
   brings up the config box, and you have to hit Open to actually
   launch that session
 - double-clicking on Default Settings from the config box will load
   them but not launch them.
On the other hand:
 - explicitly loading the Default Settings on the command line using
   `-load' _does_ still launch them.

[originally from svn r7265]
This commit is contained in:
Simon Tatham
2007-02-10 17:02:41 +00:00
parent c4893477bd
commit 5d76e00dac
3 changed files with 16 additions and 7 deletions

View File

@ -3486,7 +3486,8 @@ int pt_main(int argc, char **argv)
cmdline_run_saved(&inst->cfg);
if (!cfg_launchable(&inst->cfg) && !cfgbox(&inst->cfg))
if ((!loaded_session || !cfg_launchable(&inst->cfg)) &&
!cfgbox(&inst->cfg))
exit(0); /* config box hit Cancel */
}