summaryrefslogtreecommitdiffstats
path: root/usr.sbin
diff options
context:
space:
mode:
authordteske <dteske@FreeBSD.org>2015-06-23 04:17:12 +0000
committerdteske <dteske@FreeBSD.org>2015-06-23 04:17:12 +0000
commitcd6c92a5e0c75509fd4ce3df6e32364947f3b1f9 (patch)
tree8a5bd83ccb81c89c101173f1eafd39ef4521eda5 /usr.sbin
parentbba9917c3b9291f295e4bd24f1fdeff517af23bb (diff)
downloadFreeBSD-src-cd6c92a5e0c75509fd4ce3df6e32364947f3b1f9.zip
FreeBSD-src-cd6c92a5e0c75509fd4ce3df6e32364947f3b1f9.tar.gz
MFC r284609: Interim fix for "Login not found" error.
PR: bin/196514
Diffstat (limited to 'usr.sbin')
-rw-r--r--usr.sbin/bsdconfig/usermgmt/share/group.subr10
-rw-r--r--usr.sbin/bsdconfig/usermgmt/share/user.subr10
2 files changed, 10 insertions, 10 deletions
diff --git a/usr.sbin/bsdconfig/usermgmt/share/group.subr b/usr.sbin/bsdconfig/usermgmt/share/group.subr
index fb320d1..e9c8b16 100644
--- a/usr.sbin/bsdconfig/usermgmt/share/group.subr
+++ b/usr.sbin/bsdconfig/usermgmt/share/group.subr
@@ -82,9 +82,9 @@ f_group_add()
#
# NB: pw(8) has a ``feature'' wherein `-n name' can be taken as GID
# instead of name. Work-around is to also pass `-g GID' at the same
- # time (any GID will do; but `-1' is appropriate for this context).
+ # time (the GID is ignored in this case, so any GID will do).
#
- if [ "$input" ] && f_quietly pw groupshow -n "$input" -g -1; then
+ if [ "$input" ] && f_quietly pw groupshow -n "$input" -g 1337; then
f_show_err "$msg_group_already_used" "$input"
return $FAILURE
fi
@@ -182,7 +182,7 @@ f_group_add()
1) # Group Name (prompt for new group name)
f_dialog_input_group_name input "$group_name" ||
continue
- if f_quietly pw groupshow -n "$input" -g -1; then
+ if f_quietly pw groupshow -n "$input" -g 1337; then
f_show_err "$msg_group_already_used" "$input"
continue
fi
@@ -368,9 +368,9 @@ f_group_edit()
#
# NB: pw(8) has a ``feature'' wherein `-n name' can be taken as GID
# instead of name. Work-around is to also pass `-g GID' at the same
- # time (any GID will do; but `-1' is appropriate for this context).
+ # time (the GID is ignored in this case, so any GID will do).
#
- if [ "$input" ] && ! f_quietly pw groupshow -n "$input" -g -1; then
+ if [ "$input" ] && ! f_quietly pw groupshow -n "$input" -g 1337; then
f_show_err "$msg_group_not_found" "$input"
return $FAILURE
fi
diff --git a/usr.sbin/bsdconfig/usermgmt/share/user.subr b/usr.sbin/bsdconfig/usermgmt/share/user.subr
index d0e3887..27d9d66 100644
--- a/usr.sbin/bsdconfig/usermgmt/share/user.subr
+++ b/usr.sbin/bsdconfig/usermgmt/share/user.subr
@@ -231,9 +231,9 @@ f_user_add()
#
# NB: pw(8) has a ``feature'' wherein `-n name' can be taken as UID
# instead of name. Work-around is to also pass `-u UID' at the same
- # time (any UID will do; but `-1' is appropriate for this context).
+ # time (the UID is ignored in this case, so any UID will do).
#
- if [ "$input" ] && f_quietly pw usershow -n "$input" -u -1; then
+ if [ "$input" ] && f_quietly pw usershow -n "$input" -u 1337; then
f_show_err "$msg_login_already_used" "$input"
return $FAILURE
fi
@@ -414,7 +414,7 @@ f_user_add()
1) # Login (prompt for new login name)
f_dialog_input_name input "$user_name" ||
continue
- if f_quietly pw usershow -n "$input" -u -1; then
+ if f_quietly pw usershow -n "$input" -u 1337; then
f_show_err "$msg_login_already_used" "$input"
continue
fi
@@ -920,9 +920,9 @@ f_user_edit()
#
# NB: pw(8) has a ``feature'' wherein `-n name' can be taken as UID
# instead of name. Work-around is to also pass `-u UID' at the same
- # time (any UID will do; but `-1' is appropriate for this context).
+ # time (the UID is ignored in this case, so any UID will do).
#
- if [ "$input" ] && ! f_quietly pw usershow -n "$input" -u -1; then
+ if [ "$input" ] && ! f_quietly pw usershow -n "$input" -u 1337; then
f_show_err "$msg_login_not_found" "$input"
return $FAILURE
fi
OpenPOWER on IntegriCloud