summaryrefslogtreecommitdiff
path: root/usr.bin/chpass
diff options
context:
space:
mode:
authorRobert Nagy <robert@cvs.openbsd.org>2006-03-30 21:09:59 +0000
committerRobert Nagy <robert@cvs.openbsd.org>2006-03-30 21:09:59 +0000
commit3d4aeac38e183a03457338a4d83bc6bc21f69273 (patch)
treec6665099d833f33058906e6300a5e51753aa5f67 /usr.bin/chpass
parent1eada4599b4a4558704a2ebafc1241d47144d84b (diff)
cast to uid_t where needed; ok deraadt@
Diffstat (limited to 'usr.bin/chpass')
-rw-r--r--usr.bin/chpass/field.c8
1 files changed, 4 insertions, 4 deletions
diff --git a/usr.bin/chpass/field.c b/usr.bin/chpass/field.c
index 04aae6482a1..3e0629e622c 100644
--- a/usr.bin/chpass/field.c
+++ b/usr.bin/chpass/field.c
@@ -1,4 +1,4 @@
-/* $OpenBSD: field.c,v 1.7 2004/07/05 18:47:49 millert Exp $ */
+/* $OpenBSD: field.c,v 1.8 2006/03/30 21:09:58 robert Exp $ */
/* $NetBSD: field.c,v 1.3 1995/03/26 04:55:28 glass Exp $ */
/*
@@ -34,7 +34,7 @@
#if 0
static char sccsid[] = "@(#)field.c 8.4 (Berkeley) 4/2/94";
#else
-static char rcsid[] = "$OpenBSD: field.c,v 1.7 2004/07/05 18:47:49 millert Exp $";
+static char rcsid[] = "$OpenBSD: field.c,v 1.8 2006/03/30 21:09:58 robert Exp $";
#endif
#endif /* not lint */
@@ -111,7 +111,7 @@ p_uid(char *p, struct passwd *pw, ENTRY *ep)
warnx("empty uid field");
return (1);
}
- id = strtonum(p, 0, UID_MAX, &errstr);
+ id = (uid_t)strtonum(p, 0, UID_MAX, &errstr);
if (errstr) {
warnx("uid is %s", errstr);
return (1);
@@ -140,7 +140,7 @@ p_gid(char *p, struct passwd *pw, ENTRY *ep)
pw->pw_gid = gr->gr_gid;
return (0);
}
- id = strtonum(p, 0, GID_MAX, &errstr);
+ id = (uid_t)strtonum(p, 0, GID_MAX, &errstr);
if (errstr) {
warnx("gid is %s", errstr);
return (1);