[openssh-commits] [openssh] branch V_10_6 updated: Fix fix to !HAVE_OPENAT fallback path.
git+noreply at mindrot.org
git+noreply at mindrot.org
Thu Oct 15 23:18:47 AEDT 2026
This is an automated email from the git hooks/post-receive script.
dtucker pushed a commit to branch V_10_6
in repository openssh.
The following commit(s) were added to refs/heads/V_10_6 by this push:
new 5b9e03b58 Fix fix to !HAVE_OPENAT fallback path.
5b9e03b58 is described below
commit 5b9e03b586e3e64db661a83a42c0ee4b4d505387
Author: Darren Tucker <dtucker at dtucker.net>
AuthorDate: Thu Oct 15 23:15:23 2026 +1100
Fix fix to !HAVE_OPENAT fallback path.
The previous fix uncovered another bug where the leading "/" in the
path (or double "//") would cause earlier termination, leaving the
directory un-created. Fixes agent test on such plaforms.
---
misc.c | 4 +++-
1 file changed, 3 insertions(+), 1 deletion(-)
diff --git a/misc.c b/misc.c
index 1f4e73d64..d49c7100a 100644
--- a/misc.c
+++ b/misc.c
@@ -3330,7 +3330,9 @@ mkdir_path(const char *target, mode_t mode)
}
/* Work through the path, component-wise */
- while ((p = strsep(&dir, "/")) && *p != '\0') {
+ while ((p = strsep(&dir, "/"))) {
+ if (*p == '\0')
+ continue;
if (strlcat(path, "/", plen) >= plen ||
strlcat(path, p, plen) >= plen)
goto out;
--
To stop receiving notification emails like this one, please contact
djm at mindrot.org.
More information about the openssh-commits
mailing list