]> andersk Git - openssh.git/blobdiff - loginrec.c
- (tim) [regress/sftp-cmds.sh regress/ssh2putty.sh] Shell portability fixes
[openssh.git] / loginrec.c
index 76daaecb1c2aec1d99a98ed5cfde956139fe19e0..b411141987214f137962aad010b97715ef81e9f7 100644 (file)
 
 #include "includes.h"
 
-#include "ssh.h"
+#include <sys/types.h>
+#include <sys/stat.h>
+#include <sys/socket.h>
+
+#include <netinet/in.h>
+
+#include <errno.h>
+#include <fcntl.h>
+#ifdef HAVE_PATHS_H
+# include <paths.h>
+#endif
+#include <pwd.h>
+#include <stdarg.h>
+#include <string.h>
+#include <time.h>
+#include <unistd.h>
+
 #include "xmalloc.h"
+#include "key.h"
+#include "hostfile.h"
+#include "ssh.h"
 #include "loginrec.h"
 #include "log.h"
 #include "atomicio.h"
 # include <libutil.h>
 #endif
 
-RCSID("$Id$");
-
 /**
  ** prototypes for helper functions in this file
  **/
@@ -444,7 +461,8 @@ login_write(struct logininfo *li)
 #endif
 #ifdef CUSTOM_SYS_AUTH_RECORD_LOGIN
        if (li->type == LTYPE_LOGIN &&
-          !sys_auth_record_login(li->username,li->hostname,li->line, &loginmsg))
+           !sys_auth_record_login(li->username,li->hostname,li->line,
+           &loginmsg))
                logit("Writing login record failed for %s", li->username);
 #endif
 #ifdef SSH_AUDIT_EVENTS
@@ -1588,7 +1606,7 @@ lastlog_get_entry(struct logininfo *li)
                return (0);
        default:
                error("%s: Error reading from %s: Expecting %d, got %d",
-                   __func__, LASTLOG_FILE, sizeof(last), ret);
+                   __func__, LASTLOG_FILE, (int)sizeof(last), ret);
                return (0);
        }
 
@@ -1612,7 +1630,7 @@ record_failed_login(const char *username, const char *hostname,
        int fd;
        struct utmp ut;
        struct sockaddr_storage from;
-       size_t fromlen = sizeof(from);
+       socklen_t fromlen = sizeof(from);
        struct sockaddr_in *a4;
        struct sockaddr_in6 *a6;
        time_t t;
This page took 0.03559 seconds and 4 git commands to generate.