mirror of
https://git.openldap.org/openldap/openldap.git
synced 2025-01-18 11:05:48 +08:00
Silence gcc warnings (signed vs. unsigned, implicit declarations, unused vars).
This commit is contained in:
parent
cb61800ac6
commit
6a51371fc5
@ -729,7 +729,7 @@ getNextPage:
|
||||
i = 0;
|
||||
moreEntries = getchar();
|
||||
while ( moreEntries != EOF && moreEntries != '\n' ) {
|
||||
if ( i < sizeof(buf) - 1 ) {
|
||||
if ( i < (int)sizeof(buf) - 1 ) {
|
||||
buf[i] = moreEntries;
|
||||
i++;
|
||||
}
|
||||
|
@ -21,6 +21,7 @@
|
||||
#include <sys/types.h>
|
||||
|
||||
#include <ac/stdlib.h>
|
||||
#include <ac/string.h> /* get memcmp() */
|
||||
|
||||
#ifdef HAVE_UUID_TO_STR
|
||||
# include <sys/uuid.h>
|
||||
|
@ -748,7 +748,8 @@ str2anlist( AttributeName *an, char *in, const char *brkstr )
|
||||
int
|
||||
ad_define_option( const char *name, const char *fname, int lineno )
|
||||
{
|
||||
int i, j, len, optlen;
|
||||
int i;
|
||||
unsigned int optlen;
|
||||
|
||||
if ( options == &lang_option ) {
|
||||
options = NULL;
|
||||
|
@ -126,7 +126,7 @@ bdb_bt_compare(
|
||||
c = curkey->data;
|
||||
|
||||
#ifdef WORDS_BIGENDIAN
|
||||
for( i = 0; i < sizeof(ID); i++)
|
||||
for( i = 0; i < (int)sizeof(ID); i++)
|
||||
#else
|
||||
for( i = sizeof(ID)-1; i >= 0; i--)
|
||||
#endif
|
||||
|
@ -444,7 +444,7 @@ suffix_massage_config(
|
||||
*/
|
||||
return -1;
|
||||
|
||||
} else if ( len >= sizeof( vbuf_ ) ) {
|
||||
} else if ( len >= (int)sizeof( vbuf_ ) ) {
|
||||
/*
|
||||
* C99: snprintf returns the required size
|
||||
*/
|
||||
@ -459,7 +459,7 @@ suffix_massage_config(
|
||||
if ( len == -1 ) {
|
||||
return -1;
|
||||
|
||||
} else if ( len >= sizeof( rbuf_ ) ) {
|
||||
} else if ( len >= (int)sizeof( rbuf_ ) ) {
|
||||
rbuf = ch_malloc( len + 1 );
|
||||
len = snprintf( rbuf, sizeof( rbuf_ ), "%%1%s)%%2",
|
||||
nrnc->bv_val );
|
||||
|
@ -29,6 +29,7 @@
|
||||
|
||||
#include <stdio.h>
|
||||
|
||||
#include <ac/string.h>
|
||||
#include <ac/socket.h>
|
||||
|
||||
#define SLAPD_TOOLS
|
||||
|
Loading…
Reference in New Issue
Block a user