[openssh-commits] [openssh] branch master updated: upstream: correctly quote filenames in verbose output for local->local

git+noreply at mindrot.org git+noreply at mindrot.org
Wed Dec 3 17:30:59 AEDT 2025


This is an automated email from the git hooks/post-receive script.

djm pushed a commit to branch master
in repository openssh.

The following commit(s) were added to refs/heads/master by this push:
     new 66622394f upstream: correctly quote filenames in verbose output for local->local
66622394f is described below

commit 66622394fd3a51e9a6c99c39a068f8ba709542fa
Author: djm at openbsd.org <djm at openbsd.org>
AuthorDate: Wed Dec 3 06:29:50 2025 +0000

    upstream: correctly quote filenames in verbose output for local->local
    
    copies; from Colin Watson via bz3900; ok dtucker@
    
    OpenBSD-Commit-ID: 5c09b030e2024651ebc8c1f9af6a8a2d37912150
---
 scp.c | 11 +++++------
 1 file changed, 5 insertions(+), 6 deletions(-)

diff --git a/scp.c b/scp.c
index 85880a792..88cad7741 100644
--- a/scp.c
+++ b/scp.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: scp.c,v 1.269 2025/10/13 00:53:51 djm Exp $ */
+/* $OpenBSD: scp.c,v 1.270 2025/12/03 06:29:50 djm Exp $ */
 /*
  * scp - secure remote copy.  This is basically patched BSD rcp which
  * uses ssh to do the data transfer (instead of using rcmd).
@@ -216,7 +216,7 @@ suspchild(int signo)
 static int
 do_local_cmd(arglist *a)
 {
-	u_int i;
+	char *cp;
 	int status;
 	pid_t pid;
 
@@ -224,10 +224,9 @@ do_local_cmd(arglist *a)
 		fatal("do_local_cmd: no arguments");
 
 	if (verbose_mode) {
-		fprintf(stderr, "Executing:");
-		for (i = 0; i < a->num; i++)
-			fmprintf(stderr, " %s", a->list[i]);
-		fprintf(stderr, "\n");
+		cp = argv_assemble(a->num, a->list);
+		fmprintf(stderr, "Executing: %s\n", cp);
+		free(cp);
 	}
 	if ((pid = fork()) == -1)
 		fatal("do_local_cmd: fork: %s", strerror(errno));

-- 
To stop receiving notification emails like this one, please contact
djm at mindrot.org.


More information about the openssh-commits mailing list