summaryrefslogtreecommitdiffstats
path: root/src/util/pty/update_wtmp.c
diff options
context:
space:
mode:
authorEzra Peisach <epeisach@mit.edu>2000-06-26 23:24:38 +0000
committerEzra Peisach <epeisach@mit.edu>2000-06-26 23:24:38 +0000
commit635f9670e2c6907b58ca1756f8f2ddd3b6b11cf8 (patch)
treef5e877c24c3cd44c449a937d200de0f6d0e4172e /src/util/pty/update_wtmp.c
parent76fb3fad615c41a5e5edde4c358e67750d4ee7c5 (diff)
downloadkrb5-635f9670e2c6907b58ca1756f8f2ddd3b6b11cf8.tar.gz
krb5-635f9670e2c6907b58ca1756f8f2ddd3b6b11cf8.tar.xz
krb5-635f9670e2c6907b58ca1756f8f2ddd3b6b11cf8.zip
* libpty.h: If SOCK_DGRAM is not defined, provide a definition for
struct sockaddr_in to satisfy prototype. (based on similar code in k5-int.h). * update_wtmp.c (ptyint_update_wtmp), update_utmp.c (pty_update_utmp), open_slave.c (pty_open_slave), getpty.c (pty_getpty): conditionalize definition of variables based on code paths that are included. Essentially, clean up many compiler warnings. git-svn-id: svn://anonsvn.mit.edu/krb5/trunk@12438 dc483132-0cff-0310-8789-dd5450dbe970
Diffstat (limited to 'src/util/pty/update_wtmp.c')
-rw-r--r--src/util/pty/update_wtmp.c9
1 files changed, 6 insertions, 3 deletions
diff --git a/src/util/pty/update_wtmp.c b/src/util/pty/update_wtmp.c
index 7e8d57303f..cd714687c4 100644
--- a/src/util/pty/update_wtmp.c
+++ b/src/util/pty/update_wtmp.c
@@ -50,10 +50,13 @@ long ptyint_update_wtmp (ent , host, user)
char *host;
char *user;
{
- struct utmp ut;
- struct stat statb;
+#ifndef HAVE_UPDWTMP
int fd;
time_t uttime;
+ struct utmp ut;
+ struct stat statb;
+#endif
+
#ifdef HAVE_UPDWTMPX
struct utmpx utx;
@@ -69,7 +72,7 @@ long ptyint_update_wtmp (ent , host, user)
#ifdef HAVE_UPDWTMP
#ifndef HAVE_UPDWTMPX
-/* This is already performed byupdwtmpx if present.*/
+/* This is already performed by updwtmpx if present.*/
updwtmp(WTMP_FILE, ent);
#endif /* HAVE_UPDWTMPX*/
#else /* HAVE_UPDWTMP */