summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--scp.c12
1 files changed, 10 insertions, 2 deletions
diff --git a/scp.c b/scp.c
index b4db85198..18c277201 100644
--- a/scp.c
+++ b/scp.c
@@ -191,8 +191,16 @@ do_local_cmd(arglist *a)
191 191
192 if (verbose_mode) { 192 if (verbose_mode) {
193 fprintf(stderr, "Executing:"); 193 fprintf(stderr, "Executing:");
194 for (i = 0; i < a->num; i++) 194 for (i = 0; i < a->num; i++) {
195 fmprintf(stderr, " %s", a->list[i]); 195 if (i == 0)
196 fmprintf(stderr, " %s", a->list[i]);
197 else
198 /*
199 * TODO: misbehaves if a->list[i] contains a
200 * single quote
201 */
202 fmprintf(stderr, " '%s'", a->list[i]);
203 }
196 fprintf(stderr, "\n"); 204 fprintf(stderr, "\n");
197 } 205 }
198 if ((pid = fork()) == -1) 206 if ((pid = fork()) == -1)