Fallout from my change in the semantics of cfg.remote_cmd_ptr.
authorsimon <simon@cda61777-01e9-0310-a592-d414129be87e>
Wed, 23 Feb 2005 09:25:39 +0000 (09:25 +0000)
committersimon <simon@cda61777-01e9-0310-a592-d414129be87e>
Wed, 23 Feb 2005 09:25:39 +0000 (09:25 +0000)
Spotted by Alano na Alania.

git-svn-id: svn://svn.tartarus.org/sgt/putty@5386 cda61777-01e9-0310-a592-d414129be87e

unix/uxplink.c
windows/winplink.c

index 88d580c..42d6966 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 602ec7b..1fb3ee0 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;
 
     /*