The Samba-Bugzilla – Attachment 2703 Details for
Bug 4636
Warnings in nsswitch/pam_winbind.c
Home
|
New
|
Browse
|
Search
|
[?]
|
Reports
|
Requests
|
Help
|
New Account
|
Log In
[x]
|
Forgot Password
Login:
[x]
[patch]
silence the warnings on FreeBSD/amd64
patch-nsswitch_pam_winbind.c (text/plain), 5.61 KB, created by
Mikhail T.
on 2007-05-17 16:46:11 UTC
(
hide
)
Description:
silence the warnings on FreeBSD/amd64
Filename:
MIME Type:
Creator:
Mikhail T.
Created:
2007-05-17 16:46:11 UTC
Size:
5.61 KB
patch
obsolete
>--- nsswitch/pam_winbind.c Fri Apr 20 21:48:07 2007 >+++ nsswitch/pam_winbind.c Thu May 17 11:57:55 2007 >@@ -15,5 +15,5 @@ > #define _PAM_LOG_FUNCTION_ENTER(function, pamh, ctrl, flags) \ > do { \ >- _pam_log_debug(pamh, ctrl, LOG_DEBUG, "[pamh: 0x%08x] ENTER: " function " (flags: 0x%04x)", (uint32) pamh, flags); \ >+ _pam_log_debug(pamh, ctrl, LOG_DEBUG, "[pamh: %p] ENTER: " function " (flags: 0x%04x)", pamh, flags); \ > _pam_log_state(pamh, ctrl); \ > } while (0) >@@ -21,5 +21,5 @@ > #define _PAM_LOG_FUNCTION_LEAVE(function, pamh, ctrl, retval) \ > do { \ >- _pam_log_debug(pamh, ctrl, LOG_DEBUG, "[pamh: 0x%08x] LEAVE: " function " returning %d", (uint32) pamh, retval); \ >+ _pam_log_debug(pamh, ctrl, LOG_DEBUG, "[pamh: %p] LEAVE: " function " returning %d", pamh, retval); \ > _pam_log_state(pamh, ctrl); \ > } while (0) >@@ -33,5 +33,5 @@ > * These lead to strict aliasing warnings with gcc. > */ >-static int _pam_get_item(const pam_handle_t *pamh, int item_type, >+static int _pam_get_item(pam_handle_t *pamh, int item_type, > const void *_item) > { >@@ -39,8 +39,8 @@ > return pam_get_item(pamh, item_type, item); > } >-static int _pam_get_data(const pam_handle_t *pamh, >- const char *module_data_name, const void *_data) >+static int _pam_get_data(pam_handle_t *pamh, >+ const char *module_data_name, void *_data) > { >- const void **data = (const void **)_data; >+ void **data = (void **)_data; > return pam_get_data(pamh, module_data_name, data); > } >@@ -54,5 +54,5 @@ > } > #else >-static void _pam_log_int(const pam_handle_t *pamh, int err, const char *format, va_list args) >+static void _pam_log_int(pam_handle_t *pamh, int err, const char *format, va_list args) > { > char *format2 = NULL; >@@ -79,6 +79,6 @@ > } > >-static void _pam_log(const pam_handle_t *pamh, int ctrl, int err, const char *format, ...) PRINTF_ATTRIBUTE(4,5); >-static void _pam_log(const pam_handle_t *pamh, int ctrl, int err, const char *format, ...) >+static void _pam_log(pam_handle_t *pamh, int ctrl, int err, const char *format, ...) PRINTF_ATTRIBUTE(4,5); >+static void _pam_log(pam_handle_t *pamh, int ctrl, int err, const char *format, ...) > { > va_list args; >@@ -119,6 +119,6 @@ > } > >-static void _pam_log_debug(const pam_handle_t *pamh, int ctrl, int err, const char *format, ...) PRINTF_ATTRIBUTE(4,5); >-static void _pam_log_debug(const pam_handle_t *pamh, int ctrl, int err, const char *format, ...) >+static void _pam_log_debug(pam_handle_t *pamh, int ctrl, int err, const char *format, ...) PRINTF_ATTRIBUTE(4,5); >+static void _pam_log_debug(pam_handle_t *pamh, int ctrl, int err, const char *format, ...) > { > va_list args; >@@ -133,9 +133,9 @@ > } > >-static void _pam_log_state_datum(const pam_handle_t *pamh, int ctrl, int item_type, const char *key, int is_string) >+static void _pam_log_state_datum(pam_handle_t *pamh, int ctrl, int item_type, const char *key, int is_string) > { >- const void *data = NULL; >+ void *data = NULL; > if (item_type != 0) { >- pam_get_item(pamh, item_type, &data); >+ pam_get_item(pamh, item_type, (const void **)&data); > } else { > pam_get_data(pamh, key, &data); >@@ -144,7 +144,7 @@ > const char *type = (item_type != 0) ? "ITEM" : "DATA"; > if (is_string != 0) { >- _pam_log_debug(pamh, ctrl, LOG_DEBUG, "[pamh: 0x%08x] STATE: %s(%s) = \"%s\" (0x%08x)", (uint32) pamh, type, key, (const char *) data, (uint32) data); >+ _pam_log_debug(pamh, ctrl, LOG_DEBUG, "[pamh: %p] STATE: %s(%s) = \"%s\" (%p)", pamh, type, key, (const char *) data, data); > } else { >- _pam_log_debug(pamh, ctrl, LOG_DEBUG, "[pamh: 0x%08x] STATE: %s(%s) = 0x%08x", (uint32) pamh, type, key, (uint32) data); >+ _pam_log_debug(pamh, ctrl, LOG_DEBUG, "[pamh: %p] STATE: %s(%s) = %p", pamh, type, key, data); > } > } >@@ -172,5 +172,5 @@ > _pam_log_state_datum(pamh, ctrl, item_type, #item_type, _LOG_PASSWORD_AS_STRING) > >-static void _pam_log_state(const pam_handle_t *pamh, int ctrl) >+static void _pam_log_state(pam_handle_t *pamh, int ctrl) > { > if (!_pam_log_is_debug_state_enabled(ctrl)) { >@@ -203,5 +203,5 @@ > } > >-static int _pam_parse(const pam_handle_t *pamh, int flags, int argc, const char **argv, dictionary **result_d) >+static int _pam_parse(pam_handle_t *pamh, int flags, int argc, const char **argv, dictionary **result_d) > { > int ctrl = 0; >@@ -314,5 +314,5 @@ > int ctrl = _pam_parse(pamh, 0, 0, NULL, NULL); > if (_pam_log_is_debug_state_enabled(ctrl)) { >- _pam_log_debug(pamh, ctrl, LOG_DEBUG, "[pamh: 0x%08x] CLEAN: cleaning up PAM data 0x%08x (error_status = %d)", (uint32) pamh, (uint32) data, error_status); >+ _pam_log_debug(pamh, ctrl, LOG_DEBUG, "[pamh: %p] CLEAN: cleaning up PAM data %p (error_status = %d)", pamh, data, error_status); > } > SAFE_FREE(data); >@@ -1442,5 +1442,5 @@ > } > >-const char *get_conf_item_string(const pam_handle_t *pamh, >+const char *get_conf_item_string(pam_handle_t *pamh, > int argc, > const char **argv, >@@ -1491,10 +1491,10 @@ > } > >-const char *get_krb5_cc_type_from_config(const pam_handle_t *pamh, int argc, const char **argv, int ctrl, dictionary *d) >+const char *get_krb5_cc_type_from_config(pam_handle_t *pamh, int argc, const char **argv, int ctrl, dictionary *d) > { > return get_conf_item_string(pamh, argc, argv, ctrl, d, "krb5_ccache_type", WINBIND_KRB5_CCACHE_TYPE); > } > >-const char *get_member_from_config(const pam_handle_t *pamh, int argc, const char **argv, int ctrl, dictionary *d) >+const char *get_member_from_config(pam_handle_t *pamh, int argc, const char **argv, int ctrl, dictionary *d) > { > const char *ret = NULL; >@@ -1736,5 +1736,5 @@ > goto out; > case 0: >- pam_get_data( pamh, PAM_WINBIND_NEW_AUTHTOK_REQD, (const void **)&tmp); >+ pam_get_data( pamh, PAM_WINBIND_NEW_AUTHTOK_REQD, &tmp); > if (tmp != NULL) { > ret = atoi((const char *)tmp);
You cannot view the attachment while viewing its details because your browser does not support IFRAMEs.
View the attachment on a separate page
.
View Attachment As Raw
Actions:
View
Attachments on
bug 4636
: 2703