aboutsummaryrefslogtreecommitdiff
path: root/usr.bin/chpass
diff options
context:
space:
mode:
authorAlexander Kabaev <kan@FreeBSD.org>2003-07-11 05:47:05 +0000
committerAlexander Kabaev <kan@FreeBSD.org>2003-07-11 05:47:05 +0000
commit8a50130bbba0c21097203f701ac610019d785d33 (patch)
tree84931f6828f4b8ccd41393c4be85ba28f8e3c42a /usr.bin/chpass
parente67810e6962ed3e4f5604986cd9b0417466b80a8 (diff)
Notes
Diffstat (limited to 'usr.bin/chpass')
-rw-r--r--usr.bin/chpass/field.c4
1 files changed, 2 insertions, 2 deletions
diff --git a/usr.bin/chpass/field.c b/usr.bin/chpass/field.c
index ffa79fa31c3a..fe5b30f71049 100644
--- a/usr.bin/chpass/field.c
+++ b/usr.bin/chpass/field.c
@@ -118,7 +118,7 @@ p_uid(char *p, struct passwd *pw, ENTRY *ep __unused)
}
errno = 0;
id = strtoul(p, &np, 10);
- if (*np || (id == ULONG_MAX && errno == ERANGE)) {
+ if (*np || (id == (uid_t)ULONG_MAX && errno == ERANGE)) {
warnx("illegal uid");
return (-1);
}
@@ -148,7 +148,7 @@ p_gid(char *p, struct passwd *pw, ENTRY *ep __unused)
}
errno = 0;
id = strtoul(p, &np, 10);
- if (*np || (id == ULONG_MAX && errno == ERANGE)) {
+ if (*np || (id == (uid_t)ULONG_MAX && errno == ERANGE)) {
warnx("illegal gid");
return (-1);
}