Author: rwatson Date: Sun Apr 19 23:34:22 2009 New Revision: 191297 URL: http://svn.freebsd.org/changeset/base/191297
Log: Pass int arguments to auditon(2)'s A_GETCOND API rather than long arguments. This change should be MFC'd with OpenBSM 1.1 since they are interdependent. MFC after: 2 weeks Obtained from: TrustedBSD Project Sponsored by: Apple, Inc. Modified: head/usr.bin/login/login_audit.c Modified: head/usr.bin/login/login_audit.c ============================================================================== --- head/usr.bin/login/login_audit.c Sun Apr 19 23:28:08 2009 (r191296) +++ head/usr.bin/login/login_audit.c Sun Apr 19 23:34:22 2009 (r191297) @@ -67,10 +67,10 @@ au_login_success(void) uid_t uid = pwd->pw_uid; gid_t gid = pwd->pw_gid; pid_t pid = getpid(); - long au_cond; + int au_cond; /* If we are not auditing, don't cut an audit record; just return. */ - if (auditon(A_GETCOND, &au_cond, sizeof(long)) < 0) { + if (auditon(A_GETCOND, &au_cond, sizeof(au_cond)) < 0) { if (errno == ENOSYS) return; errx(1, "login: Could not determine audit condition"); @@ -115,13 +115,13 @@ au_login_fail(const char *errmsg, int na { token_t *tok; int aufd; - long au_cond; + int au_cond; uid_t uid; gid_t gid; pid_t pid = getpid(); /* If we are not auditing, don't cut an audit record; just return. */ - if (auditon(A_GETCOND, &au_cond, sizeof(long)) < 0) { + if (auditon(A_GETCOND, &au_cond, sizeof(au_cond)) < 0) { if (errno == ENOSYS) return; errx(1, "login: Could not determine audit condition"); @@ -175,10 +175,10 @@ audit_logout(void) uid_t uid = pwd->pw_uid; gid_t gid = pwd->pw_gid; pid_t pid = getpid(); - long au_cond; + int au_cond; /* If we are not auditing, don't cut an audit record; just return. */ - if (auditon(A_GETCOND, &au_cond, sizeof(long)) < 0) { + if (auditon(A_GETCOND, &au_cond, sizeof(int)) < 0) { if (errno == ENOSYS) return; errx(1, "login: Could not determine audit condition"); _______________________________________________ svn-src-all@freebsd.org mailing list http://lists.freebsd.org/mailman/listinfo/svn-src-all To unsubscribe, send any mail to "svn-src-all-unsubscr...@freebsd.org"