[openssh-commits] [openssh] 01/03: upstream: improve error message when trying to expand a ~user path
git+noreply at mindrot.org
git+noreply at mindrot.org
Wed Nov 10 17:32:35 AEDT 2021
This is an automated email from the git hooks/post-receive script.
djm pushed a commit to branch master
in repository openssh.
commit 6997a592ecb1013df0c6d7f8df3e6517827aef11
Author: djm at openbsd.org <djm at openbsd.org>
Date: Mon Nov 8 21:32:49 2021 +0000
upstream: improve error message when trying to expand a ~user path
for a user that doesn't exist; better matches what the shell does
ok deraadt@
OpenBSD-Commit-ID: 1ddefa3c3a78b69ce13d1b8f67bc9f2cefd23ad6
---
sftp-server.c | 4 ++--
1 file changed, 2 insertions(+), 2 deletions(-)
diff --git a/sftp-server.c b/sftp-server.c
index 1b0c42d4..3f35c399 100644
--- a/sftp-server.c
+++ b/sftp-server.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: sftp-server.c,v 1.130 2021/11/06 10:13:39 dtucker Exp $ */
+/* $OpenBSD: sftp-server.c,v 1.131 2021/11/08 21:32:49 djm Exp $ */
/*
* Copyright (c) 2000-2004 Markus Friedl. All rights reserved.
*
@@ -1557,7 +1557,7 @@ process_extended_expand(u_int32_t id)
} else {
/* ~user expansions */
if (tilde_expand(path, pw->pw_uid, &npath) != 0) {
- send_status(id, errno_to_portable(EINVAL));
+ send_status(id, errno_to_portable(ENOENT));
goto out;
}
free(path);
--
To stop receiving notification emails like this one, please contact
djm at mindrot.org.
More information about the openssh-commits
mailing list