X-Git-Url: https://git.distorted.org.uk/~mdw/sgt/putty/blobdiff_plain/8cdf0e5fddf29be73a94e856c5b656e4715990d7..e66c3912e1b12d8a95b818a316c70ec6b4383aef:/unix/uxplink.c?ds=sidebyside diff --git a/unix/uxplink.c b/unix/uxplink.c index 88d580c7..8d1aac74 100644 --- a/unix/uxplink.c +++ b/unix/uxplink.c @@ -217,7 +217,6 @@ static void usage(void) printf(" force use of a particular protocol\n"); printf(" -P port connect to specified port\n"); printf(" -l user connect with specified username\n"); - printf(" -m file read remote command(s) from file\n"); printf(" -batch disable all interactive prompts\n"); printf("The following options only apply to SSH connections:\n"); printf(" -pw passw login with specified password\n"); @@ -234,6 +233,7 @@ static void usage(void) printf(" -4 -6 force use of IPv4 or IPv6\n"); printf(" -C enable compression\n"); printf(" -i key private key file for authentication\n"); + printf(" -m file read remote command(s) from file\n"); printf(" -s remote command is an SSH subsystem (SSH-2 only)\n"); printf(" -N don't start a shell/command (SSH-2 only)\n"); exit(1); @@ -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; /*