ITS#9901 libldap: fix non-std printf %p arguments

This commit is contained in:
Michael Osipov 2022-08-09 17:33:35 +02:00 committed by Quanah Gibson-Mount
parent f76dbe43aa
commit 519e0c94c9
3 changed files with 9 additions and 8 deletions

View File

@ -266,9 +266,9 @@ ber_dump(
}
sprintf( buf, "ber_dump: buf=%p ptr=%p end=%p len=%ld\n",
ber->ber_buf,
ber->ber_ptr,
ber->ber_end,
(void *) ber->ber_buf,
(void *) ber->ber_ptr,
(void *) ber->ber_end,
(long) len );
(void) (*ber_pvt_log_print)( buf );

View File

@ -20,6 +20,7 @@
#include <ac/string.h>
#include <ac/ctype.h>
#include <lutil.h>
#include <unistd.h>
#if !defined(HAVE_VSNPRINTF) && !defined(HAVE_EBCDIC)
/* Write at most n characters to the buffer in str, return the

View File

@ -961,7 +961,7 @@ ldap_do_free_request( void *arg )
Debug3( LDAP_DEBUG_TRACE, "ldap_do_free_request: "
"asked to free lr %p msgid %d refcnt %d\n",
lr, lr->lr_msgid, lr->lr_refcnt );
(void *) lr, lr->lr_msgid, lr->lr_refcnt );
/* if lr_refcnt > 0, the request has been looked up
* by ldap_find_request_by_msgid(); if in the meanwhile
* the request is free()'d by someone else, just decrease
@ -1008,7 +1008,7 @@ ldap_free_request_int( LDAP *ld, LDAPRequest *lr )
assert( !removed || removed == lr );
Debug3( LDAP_DEBUG_TRACE, "ldap_free_request_int: "
"lr %p msgid %d%s removed\n",
lr, lr->lr_msgid, removed ? "" : " not" );
(void *) lr, lr->lr_msgid, removed ? "" : " not" );
ldap_do_free_request( lr );
}
@ -1673,12 +1673,12 @@ ldap_find_request_by_msgid( LDAP *ld, ber_int_t msgid )
lr->lr_refcnt++;
Debug3( LDAP_DEBUG_TRACE, "ldap_find_request_by_msgid: "
"msgid %d, lr %p lr->lr_refcnt = %d\n",
msgid, lr, lr->lr_refcnt );
msgid, (void *) lr, lr->lr_refcnt );
return lr;
}
Debug2( LDAP_DEBUG_TRACE, "ldap_find_request_by_msgid: "
"msgid %d, lr %p\n", msgid, lr );
"msgid %d, lr %p\n", msgid, (void *) lr );
return NULL;
}
@ -1690,7 +1690,7 @@ ldap_return_request( LDAP *ld, LDAPRequest *lrx, int freeit )
lr = ldap_tavl_find( ld->ld_requests, lrx, ldap_req_cmp );
Debug2( LDAP_DEBUG_TRACE, "ldap_return_request: "
"lrx %p, lr %p\n", lrx, lr );
"lrx %p, lr %p\n", (void *) lrx, (void *) lr );
if ( lr ) {
assert( lr == lrx );
if ( lr->lr_refcnt > 0 ) {