]> asedeno.scripts.mit.edu Git - PuTTY.git/commitdiff
Fallout from my change in the semantics of cfg.remote_cmd_ptr.
authorSimon Tatham <anakin@pobox.com>
Wed, 23 Feb 2005 09:25:39 +0000 (09:25 +0000)
committerSimon Tatham <anakin@pobox.com>
Wed, 23 Feb 2005 09:25:39 +0000 (09:25 +0000)
Spotted by Alano na Alania.

[originally from svn r5386]

unix/uxplink.c
windows/winplink.c

index 88d580c73f7b430a476b1c894c22844c02c01b6e..42d6966462b38c7771478d4adcd259dfd1d1ac19 100644 (file)
@@ -414,8 +414,6 @@ int main(int argc, char **argv)
                            cfg.port = default_port;
                        } else {
                            cfg = cfg2;
-                           /* Ick: patch up internal pointer after copy */
-                           cfg.remote_cmd_ptr = cfg.remote_cmd;
                        }
                    }
 
@@ -518,7 +516,7 @@ int main(int argc, char **argv)
        cfg.host[p1] = '\0';
     }
 
-    if (!*cfg.remote_cmd_ptr)
+    if (!cfg.remote_cmd_ptr && !*cfg.remote_cmd)
        flags |= FLAG_INTERACTIVE;
 
     /*
index 602ec7bcbfe28d0858cb92cd976c4d9dfd18a609..1fb3ee0b14bfa781ecbbbdb6a3061c5516e76391 100644 (file)
@@ -425,8 +425,6 @@ int main(int argc, char **argv)
                            cfg.port = default_port;
                        } else {
                            cfg = cfg2;
-                           /* Ick: patch up internal pointer after copy */
-                           cfg.remote_cmd_ptr = cfg.remote_cmd;
                        }
                    }
 
@@ -529,7 +527,7 @@ int main(int argc, char **argv)
        cfg.host[p1] = '\0';
     }
 
-    if (!*cfg.remote_cmd_ptr)
+    if (!cfg.remote_cmd_ptr && !*cfg.remote_cmd)
        flags |= FLAG_INTERACTIVE;
 
     /*