diff options
author | 2006-03-25 18:36:15 +0000 | |
---|---|---|
committer | 2006-03-25 18:36:15 +0000 | |
commit | 30ba66d46d03fa4f0f71a5c9c7c0fd5e6f2344ea (patch) | |
tree | f49f7a812563ed8b3f7e439c51d29eb9e99517b2 | |
parent | spacing (diff) | |
download | wireguard-openbsd-30ba66d46d03fa4f0f71a5c9c7c0fd5e6f2344ea.tar.xz wireguard-openbsd-30ba66d46d03fa4f0f71a5c9c7c0fd5e6f2344ea.zip |
nicer size_t and time_t types
-rw-r--r-- | usr.bin/ssh/sshlogin.c | 8 | ||||
-rw-r--r-- | usr.bin/ssh/sshlogin.h | 4 |
2 files changed, 6 insertions, 6 deletions
diff --git a/usr.bin/ssh/sshlogin.c b/usr.bin/ssh/sshlogin.c index da9c293e25e..2cc160901ae 100644 --- a/usr.bin/ssh/sshlogin.c +++ b/usr.bin/ssh/sshlogin.c @@ -1,4 +1,4 @@ -/* $OpenBSD: sshlogin.c,v 1.16 2006/03/25 13:17:03 djm Exp $ */ +/* $OpenBSD: sshlogin.c,v 1.17 2006/03/25 18:36:15 deraadt Exp $ */ /* * Author: Tatu Ylonen <ylo@cs.hut.fi> * Copyright (c) 1995 Tatu Ylonen <ylo@cs.hut.fi>, Espoo, Finland @@ -56,9 +56,9 @@ extern ServerOptions options; * information is not available. This must be called before record_login. * The host the user logged in from will be returned in buf. */ -u_long +time_t get_last_login_time(uid_t uid, const char *logname, - char *buf, u_int bufsize) + char *buf, size_t bufsize) { struct lastlog ll; char *lastlog; @@ -91,7 +91,7 @@ get_last_login_time(uid_t uid, const char *logname, bufsize = sizeof(ll.ll_host) + 1; strncpy(buf, ll.ll_host, bufsize - 1); buf[bufsize - 1] = '\0'; - return ll.ll_time; + return (time_t)ll.ll_time; } /* diff --git a/usr.bin/ssh/sshlogin.h b/usr.bin/ssh/sshlogin.h index 10e7e6ea8cc..1bb013b407d 100644 --- a/usr.bin/ssh/sshlogin.h +++ b/usr.bin/ssh/sshlogin.h @@ -1,4 +1,4 @@ -/* $OpenBSD: sshlogin.h,v 1.4 2002/08/29 15:57:25 stevesk Exp $ */ +/* $OpenBSD: sshlogin.h,v 1.5 2006/03/25 18:36:15 deraadt Exp $ */ /* * Author: Tatu Ylonen <ylo@cs.hut.fi> @@ -18,6 +18,6 @@ void record_login(pid_t, const char *, const char *, uid_t, const char *, struct sockaddr *, socklen_t); void record_logout(pid_t, const char *); -u_long get_last_login_time(uid_t, const char *, char *, u_int); +time_t get_last_login_time(uid_t, const char *, char *, size_t); #endif |