]> asedeno.scripts.mit.edu Git - PuTTY.git/blobdiff - unix/gtkmain.c
Omit the conf_launchable check in pterm Duplicate Session.
[PuTTY.git] / unix / gtkmain.c
index 5e8b9fe25fcd5242202f53962a009fb72404b835..a7b4a4e918681002b50771dd4423a4c93a6ccd84 100644 (file)
@@ -532,15 +532,27 @@ int do_cmdline(int argc, char **argv, int do_everything, int *allow_launch,
     return err;
 }
 
+GtkWidget *make_gtk_toplevel_window(void *frontend)
+{
+    return gtk_window_new(GTK_WINDOW_TOPLEVEL);
+}
+
 extern int cfgbox(Conf *conf);
 
-int pt_main(int argc, char **argv)
+int main(int argc, char **argv)
 {
     Conf *conf;
     int need_config_box;
 
     setlocale(LC_CTYPE, "");
 
+    {
+        /* Call the function in ux{putty,pterm}.c to do app-type
+         * specific setup */
+        extern void setup(int);
+        setup(TRUE);     /* TRUE means we are a one-session process */
+    }
+
     progname = argv[0];
 
     /*
@@ -570,11 +582,13 @@ int pt_main(int argc, char **argv)
     block_signal(SIGPIPE, 1);
 
     if (argc > 1 && !strncmp(argv[1], "---", 3)) {
+        extern const int dup_check_launchable;
+
        read_dupsession_data(conf, argv[1]);
        /* Splatter this argument so it doesn't clutter a ps listing */
        smemclr(argv[1], strlen(argv[1]));
 
-        assert(conf_launchable(conf));
+        assert(!dup_check_launchable || conf_launchable(conf));
         need_config_box = FALSE;
     } else {
        /* By default, we bring up the config dialog, rather than launching