diff options
author | des <des@FreeBSD.org> | 2003-12-11 13:55:16 +0000 |
---|---|---|
committer | des <des@FreeBSD.org> | 2003-12-11 13:55:16 +0000 |
commit | 9c38a557979e384e5fc0e3b85507242bee98321f (patch) | |
tree | 79f074d7b6c050b037a9004caf920936f5c2abf9 /lib/libpam/modules/pam_echo/pam_echo.c | |
parent | 0b146f01b2bf8034a394e4136235609dddda45bf (diff) | |
download | FreeBSD-src-9c38a557979e384e5fc0e3b85507242bee98321f.zip FreeBSD-src-9c38a557979e384e5fc0e3b85507242bee98321f.tar.gz |
Fix strict aliasing breakage in PAM modules (except pam_krb5, which needs
more work than the others). This should make most modules build with -O2.
Diffstat (limited to 'lib/libpam/modules/pam_echo/pam_echo.c')
-rw-r--r-- | lib/libpam/modules/pam_echo/pam_echo.c | 5 |
1 files changed, 3 insertions, 2 deletions
diff --git a/lib/libpam/modules/pam_echo/pam_echo.c b/lib/libpam/modules/pam_echo/pam_echo.c index 48882f6..ff00859 100644 --- a/lib/libpam/modules/pam_echo/pam_echo.c +++ b/lib/libpam/modules/pam_echo/pam_echo.c @@ -48,7 +48,8 @@ _pam_echo(pam_handle_t *pamh, int flags, int argc, const char *argv[]) { char msg[PAM_MAX_MSG_SIZE]; - const char *str, *p, *q; + const void *str; + const char *p, *q; int err, i, item; size_t len; @@ -89,7 +90,7 @@ _pam_echo(pam_handle_t *pamh, int flags, } if (item == -1) continue; - err = pam_get_item(pamh, item, (const void **)&str); + err = pam_get_item(pamh, item, &str); if (err != PAM_SUCCESS) return (err); if (str == NULL) |