- (dtucker) [openbsd-compat/port-aix.c] Silence compiler warnings.

This commit is contained in:
Darren Tucker 2005-02-08 21:06:55 +11:00
parent feb6f7f244
commit b4d3012d2e
2 changed files with 13 additions and 5 deletions

View File

@ -2,6 +2,7 @@
- (dtucker) [regress/test-exec.sh] Bug #912: Set _POSIX2_VERSION for the - (dtucker) [regress/test-exec.sh] Bug #912: Set _POSIX2_VERSION for the
regress tests so newer versions of GNU head(1) behave themselves. Patch regress tests so newer versions of GNU head(1) behave themselves. Patch
by djm, so ok me. by djm, so ok me.
- (dtucker) [openbsd-compat/port-aix.c] Silence compiler warnings.
20050204 20050204
- (dtucker) [monitor.c] Permit INVALID_USER audit events from slave too. - (dtucker) [monitor.c] Permit INVALID_USER audit events from slave too.
@ -2081,4 +2082,4 @@
- (djm) Trim deprecated options from INSTALL. Mention UsePAM - (djm) Trim deprecated options from INSTALL. Mention UsePAM
- (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu - (djm) Fix quote handling in sftp; Patch from admorten AT umich.edu
$Id: ChangeLog,v 1.3637 2005/02/08 09:17:17 dtucker Exp $ $Id: ChangeLog,v 1.3638 2005/02/08 10:06:55 dtucker Exp $

View File

@ -36,6 +36,10 @@
#include <uinfo.h> #include <uinfo.h>
#include "port-aix.h" #include "port-aix.h"
/* These should be in the system headers but are not. */
int usrinfo(int, char *, int);
int setauthdb(const char *, char *);
extern Buffer loginmsg; extern Buffer loginmsg;
# ifdef HAVE_SETAUTHDB # ifdef HAVE_SETAUTHDB
@ -49,6 +53,8 @@ static char old_registry[REGISTRY_SIZE] = "";
* NOTE: TTY= should be set, but since no one uses it and it's hard to * NOTE: TTY= should be set, but since no one uses it and it's hard to
* acquire due to privsep code. We will just drop support. * acquire due to privsep code. We will just drop support.
*/ */
void void
aix_usrinfo(struct passwd *pw) aix_usrinfo(struct passwd *pw)
{ {
@ -260,10 +266,10 @@ sys_auth_record_login(const char *user, const char *host, const char *ttynm)
int success = 0; int success = 0;
aix_setauthdb(user); aix_setauthdb(user);
if (loginsuccess((char *)user, host, ttynm, &msg) == 0) { if (loginsuccess((char *)user, (char *)host, (char *)ttynm, &msg) == 0) {
success = 1; success = 1;
if (msg != NULL) { if (msg != NULL) {
debug("AIX/loginsuccess: msg %s", __func__, msg); debug("AIX/loginsuccess: msg %s", msg);
buffer_append(&loginmsg, msg, strlen(msg)); buffer_append(&loginmsg, msg, strlen(msg));
xfree(msg); xfree(msg);
} }
@ -284,9 +290,10 @@ record_failed_login(const char *user, const char *hostname, const char *ttyname)
aix_setauthdb(user); aix_setauthdb(user);
# ifdef AIX_LOGINFAILED_4ARG # ifdef AIX_LOGINFAILED_4ARG
loginfailed((char *)user, hostname, (char *)ttyname, AUDIT_FAIL_AUTH); loginfailed((char *)user, (char *)hostname, (char *)ttyname,
AUDIT_FAIL_AUTH);
# else # else
loginfailed((char *)user, hostname, (char *)ttyname); loginfailed((char *)user, (char *)hostname, (char *)ttyname);
# endif # endif
aix_restoreauthdb(); aix_restoreauthdb();
} }