diff options
author | Mike Gilbert <floppym@gentoo.org> | 2023-06-25 13:49:06 -0400 |
---|---|---|
committer | Mike Gilbert <floppym@gentoo.org> | 2023-06-26 14:57:38 -0400 |
commit | e6f14e5d76fff757860691c7aa2f94172018711a (patch) | |
tree | 59b968ad17e263680b763e0bfa894a5fccbe5f84 /eclass/acct-user.eclass | |
parent | acct-user.eclass: improve error message when usermod fails (diff) | |
download | gentoo-e6f14e5d76fff757860691c7aa2f94172018711a.tar.gz gentoo-e6f14e5d76fff757860691c7aa2f94172018711a.tar.bz2 gentoo-e6f14e5d76fff757860691c7aa2f94172018711a.zip |
acct-user.eclass: include exit status in death message
Signed-off-by: Mike Gilbert <floppym@gentoo.org>
Diffstat (limited to 'eclass/acct-user.eclass')
-rw-r--r-- | eclass/acct-user.eclass | 6 |
1 files changed, 3 insertions, 3 deletions
diff --git a/eclass/acct-user.eclass b/eclass/acct-user.eclass index b2ac02b2b972..f658aa0eabc3 100644 --- a/eclass/acct-user.eclass +++ b/eclass/acct-user.eclass @@ -362,7 +362,7 @@ acct-user_pkg_preinst() { fi elog "Adding user ${ACCT_USER_NAME}" - useradd "${opts[@]}" "${ACCT_USER_NAME}" || die + useradd "${opts[@]}" "${ACCT_USER_NAME}" || die "useradd failed with status $?" _ACCT_USER_ADDED=1 fi @@ -454,7 +454,7 @@ acct-user_pkg_postinst() { eerror " usermod ${optsq[*]} ${ACCT_USER_NAME}" else eerror "$(<"${T}/usermod-error.log")" - die "usermod failed" + die "usermod failed with status ${status}" fi fi } @@ -502,7 +502,7 @@ acct-user_pkg_prerm() { fi elog "Locking user ${ACCT_USER_NAME}" - usermod "${opts[@]}" "${ACCT_USER_NAME}" || die + usermod "${opts[@]}" "${ACCT_USER_NAME}" || die "usermod failed with status $?" } fi |