git: ed54170f89bb - stable/15 - pw: fix incorrect metalog path in mkdir_home_parents

From: Baptiste Daroussin <bapt_at_FreeBSD.org>
Date: Sun, 28 Jun 2026 18:40:37 UTC
The branch stable/15 has been updated by bapt:

URL: https://cgit.FreeBSD.org/src/commit/?id=ed54170f89bb481ee8fe9878e8591eaf6d761e8d

commit ed54170f89bb481ee8fe9878e8591eaf6d761e8d
Author:     Baptiste Daroussin <bapt@FreeBSD.org>
AuthorDate: 2026-06-04 22:19:54 +0000
Commit:     Baptiste Daroussin <bapt@FreeBSD.org>
CommitDate: 2026-06-28 18:32:27 +0000

    pw: fix incorrect metalog path in mkdir_home_parents
    
    (cherry picked from commit ab478de1f9b3f73036ee05004fb2d503a0f339bc)
---
 usr.sbin/pw/pw_user.c | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/usr.sbin/pw/pw_user.c b/usr.sbin/pw/pw_user.c
index dcf870ca1edc..abb8a09ce468 100644
--- a/usr.sbin/pw/pw_user.c
+++ b/usr.sbin/pw/pw_user.c
@@ -123,7 +123,7 @@ mkdir_home_parents(int dfd, const char *dir)
 					    dirs);
 				if (fchownat(dfd, dirs, 0, 0, 0) != 0)
 					warn("chown(%s)", dirs);
-				metalog_emit(dir,
+				metalog_emit(dirs,
 				    (_DEF_DIRMODE | S_IFDIR) & ~pumask, 0, 0,
 				    0);
 			}