diff options
author | peter <peter@FreeBSD.org> | 2001-10-27 02:13:41 +0000 |
---|---|---|
committer | peter <peter@FreeBSD.org> | 2001-10-27 02:13:41 +0000 |
commit | 5a0fafd56a01e4faa2d0c40d2c15bc16c5780149 (patch) | |
tree | 8410ee6d90f1b6ef9efce00a46a15979bf1f4607 /lib | |
parent | 8972891811456ffcfe6a96c0a9797ae64f8129ab (diff) | |
download | FreeBSD-src-5a0fafd56a01e4faa2d0c40d2c15bc16c5780149.zip FreeBSD-src-5a0fafd56a01e4faa2d0c40d2c15bc16c5780149.tar.gz |
Explicitly use int32_t for on-disk records for pw_change and pw_expire,
since that is what we use now and this insulates us from any time_t
tweaks here. We can define a record format that uses 64 bit times if/when
we need to.
Diffstat (limited to 'lib')
-rw-r--r-- | lib/libc/gen/getpwent.c | 7 |
1 files changed, 5 insertions, 2 deletions
diff --git a/lib/libc/gen/getpwent.c b/lib/libc/gen/getpwent.c index ae384ba..547675f 100644 --- a/lib/libc/gen/getpwent.c +++ b/lib/libc/gen/getpwent.c @@ -1129,6 +1129,7 @@ __hashpw(key) char *p, *t; static u_int max; static char *buf; + int32_t pw_change, pw_expire; DBT data; switch ((_pw_db->get)(_pw_db, key, &data, 0)) { @@ -1154,13 +1155,15 @@ __hashpw(key) EXPAND(_pw_passwd.pw_passwd); SCALAR(_pw_passwd.pw_uid); SCALAR(_pw_passwd.pw_gid); - SCALAR(_pw_passwd.pw_change); + SCALAR(pw_change); EXPAND(_pw_passwd.pw_class); EXPAND(_pw_passwd.pw_gecos); EXPAND(_pw_passwd.pw_dir); EXPAND(_pw_passwd.pw_shell); - SCALAR(_pw_passwd.pw_expire); + SCALAR(pw_expire); SCALAR(_pw_passwd.pw_fields); + _pw_passwd.pw_change = pw_change; + _pw_passwd.pw_expire = pw_expire; return NS_SUCCESS; } |