summaryrefslogtreecommitdiffstats
path: root/defines.h
diff options
context:
space:
mode:
authorDamien Miller <djm@mindrot.org>2000-12-20 13:34:48 +1100
committerDamien Miller <djm@mindrot.org>2000-12-20 13:34:48 +1100
commit82cf0ceea899d4c7a47bdec79eea6dc2a8576bc7 (patch)
treef9011833137c0c5589ebe0b5fb45da9ddc069bca /defines.h
parent28bfc0da69166bc1afe33cfb1a61dadce01169e2 (diff)
- (djm) Workaround PAM inconsistencies between Solaris derived PAM code
and Linux-PAM. Based on report and fix from Andrew Morgan <morgan@transmeta.com>
Diffstat (limited to 'defines.h')
-rw-r--r--defines.h6
1 files changed, 6 insertions, 0 deletions
diff --git a/defines.h b/defines.h
index 642b0079..4c3941ca 100644
--- a/defines.h
+++ b/defines.h
@@ -340,6 +340,12 @@ struct winsize {
# define PAM_STRERROR(a,b) pam_strerror((a),(b))
#endif
+#ifdef PAM_SUN_CODEBASE
+# define PAM_MSG_MEMBER(msg, n, member) ((*(msg))[(n)].member)
+#else
+# define PAM_MSG_MEMBER(msg, n, member) ((msg)[(n)]->member)
+#endif
+
#if defined(BROKEN_GETADDRINFO) && defined(HAVE_GETADDRINFO)
# undef HAVE_GETADDRINFO
#endif /* defined(BROKEN_GETADDRINFO) && defined(HAVE_GETADDRINFO) */