summaryrefslogtreecommitdiffstats
path: root/pw/pw_group.c
diff options
context:
space:
mode:
authorDavid Nugent <davidn@FreeBSD.org>1996-12-19 15:22:45 +0000
committerDavid Nugent <davidn@FreeBSD.org>1996-12-19 15:22:45 +0000
commitfb318265f4aee122f20f5750cea5238f9baddffc (patch)
treec8590d2025a0e577a5de528f8195deb38edd5a0f /pw/pw_group.c
parent70b52c92e25b591a71e7a773a064bc8709264454 (diff)
downloadpw-darwin-fb318265f4aee122f20f5750cea5238f9baddffc.tar.gz
pw-darwin-fb318265f4aee122f20f5750cea5238f9baddffc.tar.zst
pw-darwin-fb318265f4aee122f20f5750cea5238f9baddffc.zip
Allow 8-bit characters in the passwd gecos field, and adds a paragraph
to the mangpage explaining the consequences (to be updated at a later date after login class conf support is added).
Diffstat (limited to 'pw/pw_group.c')
-rw-r--r--pw/pw_group.c6
1 files changed, 3 insertions, 3 deletions
diff --git a/pw/pw_group.c b/pw/pw_group.c
index 7bd99a1..8097297 100644
--- a/pw/pw_group.c
+++ b/pw/pw_group.c
@@ -23,7 +23,7 @@
* OUT OF THE USE OF THIS SOFTWARE, EVEN IF ADVISED OF THE POSSIBILITY OF
* SUCH DAMAGE.
*
- * $Id: pw_group.c,v 1.1.1.2 1996/12/09 23:55:25 joerg Exp $
+ * $Id: pw_group.c,v 1.1.1.3 1996/12/10 23:59:01 joerg Exp $
*/
#include <unistd.h>
@@ -119,7 +119,7 @@ pw_group(struct userconf * cnf, int mode, struct cargs * args)
grp->gr_gid = (gid_t) atoi(a_gid->val);
if ((arg = getarg(args, 'l')) != NULL)
- grp->gr_name = arg->val;
+ grp->gr_name = pw_checkname((u_char *)arg->val, 0);
} else {
if (a_name == NULL) /* Required */
cmderr(EX_DATAERR, "group name required\n");
@@ -128,7 +128,7 @@ pw_group(struct userconf * cnf, int mode, struct cargs * args)
memset(members, 0, sizeof members);
grp = &fakegroup;
- grp->gr_name = a_name->val;
+ grp->gr_name = pw_checkname((u_char *)a_name->val, 0);
grp->gr_passwd = "*";
grp->gr_gid = gr_gidpolicy(cnf, args);
grp->gr_mem = members;