From 622dedf1a884f2927a9121e672bd9955e12ba108 Mon Sep 17 00:00:00 2001 From: "tb@openbsd.org" Date: Mon, 21 Jan 2019 22:50:42 +0000 Subject: upstream: Add a -J option as a shortcut for -o Proxyjump= to scp(1) and sftp(1) to match ssh(1)'s interface. ok djm OpenBSD-Commit-ID: a75bc2d5f329caa7229a7e9fe346c4f41c2663fc --- sftp.c | 14 +++++++------- 1 file changed, 7 insertions(+), 7 deletions(-) (limited to 'sftp.c') diff --git a/sftp.c b/sftp.c index 0f3f89d33..44aa19d96 100644 --- a/sftp.c +++ b/sftp.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sftp.c,v 1.189 2019/01/16 23:23:45 djm Exp $ */ +/* $OpenBSD: sftp.c,v 1.190 2019/01/21 22:50:42 tb Exp $ */ /* * Copyright (c) 2001-2004 Damien Miller * @@ -2362,11 +2362,10 @@ usage(void) fprintf(stderr, "usage: %s [-46aCfpqrv] [-B buffer_size] [-b batchfile] [-c cipher]\n" - " [-D sftp_server_path] [-F ssh_config] " - "[-i identity_file] [-l limit]\n" - " [-o ssh_option] [-P port] [-R num_requests] " - "[-S program]\n" - " [-s subsystem | sftp_server] destination\n", + " [-D sftp_server_path] [-F ssh_config] [-i identity_file]\n" + " [-J destination] [-l limit] [-o ssh_option] [-P port]\n" + " [-R num_requests] [-S program] [-s subsystem | sftp_server]\n" + " destination\n", __progname); exit(1); } @@ -2409,7 +2408,7 @@ main(int argc, char **argv) infile = stdin; while ((ch = getopt(argc, argv, - "1246afhpqrvCc:D:i:l:o:s:S:b:B:F:P:R:")) != -1) { + "1246afhpqrvCc:D:i:l:o:s:S:b:B:F:J:P:R:")) != -1) { switch (ch) { /* Passed through to ssh(1) */ case '4': @@ -2419,6 +2418,7 @@ main(int argc, char **argv) break; /* Passed through to ssh(1) with argument */ case 'F': + case 'J': case 'c': case 'i': case 'o': -- cgit v1.2.3