X-Git-Url: https://git.distorted.org.uk/u/mdw/putty/blobdiff_plain/755e0524eb217ebed9f649405fa2624b26f0fb29..2ac3322ef9bc032ad942753a56696764aa0b0f74:/unix/gtkwin.c diff --git a/unix/gtkwin.c b/unix/gtkwin.c index 043f519f..c93aedad 100644 --- a/unix/gtkwin.c +++ b/unix/gtkwin.c @@ -95,6 +95,7 @@ struct gui_data { char *progname, **gtkargvstart; int ngtkargs; guint32 input_event_time; /* Timestamp of the most recent input event. */ + int reconfiguring; }; struct draw_ctx { @@ -1169,7 +1170,7 @@ void notify_remote_exit(void *frontend) inst->exited = TRUE; if (inst->cfg.close_on_exit == FORCE_ON || (inst->cfg.close_on_exit == AUTO && exitcode == 0)) - exit(0); /* just go. */ + gtk_main_quit(); /* just go */ if (inst->ldisc) { ldisc_free(inst->ldisc); inst->ldisc = NULL; @@ -2560,7 +2561,11 @@ int do_cmdline(int argc, char **argv, int do_everything, } else if(!strcmp(p, "-help") || !strcmp(p, "--help")) { help(stdout); exit(0); - + + } else if (!strcmp(p, "-pgpfp")) { + pgp_fingerprints(); + exit(1); + } else if(p[0] != '-' && (!do_everything || process_nonoption_arg(p, cfg))) { /* do nothing */ @@ -2878,6 +2883,11 @@ void change_settings_menuitem(GtkMenuItem *item, gpointer data) assert(lenof(ww) == NCFGCOLOURS); + if (inst->reconfiguring) + return; + else + inst->reconfiguring = TRUE; + cfg2 = inst->cfg; /* structure copy */ if (do_config_box(title, &cfg2, 1, @@ -2995,6 +3005,7 @@ void change_settings_menuitem(GtkMenuItem *item, gpointer data) gtk_widget_queue_draw(inst->area); } sfree(title); + inst->reconfiguring = FALSE; } void fork_and_exec_self(struct gui_data *inst, int fd_to_close, ...)