|
Lines 131-136
Link Here
|
| 131 |
/* This is the program to execute for the secured connection. ("ssh" or -S) */ |
131 |
/* This is the program to execute for the secured connection. ("ssh" or -S) */ |
| 132 |
char *ssh_program = _PATH_SSH_PROGRAM; |
132 |
char *ssh_program = _PATH_SSH_PROGRAM; |
| 133 |
|
133 |
|
|
|
134 |
/* This is the remote name of the scp program ("scp" or -R) */ |
| 135 |
char *scp_program = "scp"; |
| 136 |
|
| 134 |
/* This is used to store the pid of ssh_program */ |
137 |
/* This is used to store the pid of ssh_program */ |
| 135 |
pid_t do_cmd_pid = -1; |
138 |
pid_t do_cmd_pid = -1; |
| 136 |
|
139 |
|
|
Lines 313-319
Link Here
|
| 313 |
addargs(&args, "-oClearAllForwardings yes"); |
316 |
addargs(&args, "-oClearAllForwardings yes"); |
| 314 |
|
317 |
|
| 315 |
fflag = tflag = 0; |
318 |
fflag = tflag = 0; |
| 316 |
while ((ch = getopt(argc, argv, "dfl:prtvBCc:i:P:q1246S:o:F:")) != -1) |
319 |
while ((ch = getopt(argc, argv, "dfl:prtvBCc:i:P:q1246S:o:F:R:")) != -1) |
| 317 |
switch (ch) { |
320 |
switch (ch) { |
| 318 |
/* User-visible flags. */ |
321 |
/* User-visible flags. */ |
| 319 |
case '1': |
322 |
case '1': |
|
Lines 347-352
Link Here
|
| 347 |
case 'r': |
350 |
case 'r': |
| 348 |
iamrecursive = 1; |
351 |
iamrecursive = 1; |
| 349 |
break; |
352 |
break; |
|
|
353 |
case 'R': |
| 354 |
scp_program = xstrdup(optarg); |
| 355 |
break; |
| 350 |
case 'S': |
356 |
case 'S': |
| 351 |
ssh_program = xstrdup(optarg); |
357 |
ssh_program = xstrdup(optarg); |
| 352 |
break; |
358 |
break; |
|
Lines 408-414
Link Here
|
| 408 |
remin = remout = -1; |
414 |
remin = remout = -1; |
| 409 |
do_cmd_pid = -1; |
415 |
do_cmd_pid = -1; |
| 410 |
/* Command to be executed on remote system using "ssh". */ |
416 |
/* Command to be executed on remote system using "ssh". */ |
| 411 |
(void) snprintf(cmd, sizeof cmd, "scp%s%s%s%s", |
417 |
(void) snprintf(cmd, sizeof cmd, "%s%s%s%s%s", |
|
|
418 |
scp_program, |
| 412 |
verbose_mode ? " -v" : "", |
419 |
verbose_mode ? " -v" : "", |
| 413 |
iamrecursive ? " -r" : "", pflag ? " -p" : "", |
420 |
iamrecursive ? " -r" : "", pflag ? " -p" : "", |
| 414 |
targetshouldbedirectory ? " -d" : ""); |
421 |
targetshouldbedirectory ? " -d" : ""); |