ITS#10515 slapd/config: Windows compat

Newer gcc insists on arguments matching prototypes
This commit is contained in:
Howard Chu 2026-06-01 16:26:09 +01:00
parent da5c3aff72
commit 07d0823141
3 changed files with 7 additions and 5 deletions

View file

@ -54,9 +54,11 @@
#ifdef _WIN32
#define LUTIL_ATOULX lutil_atoullx
#define Z "I"
#define ULTYPE unsigned long long
#else
#define LUTIL_ATOULX lutil_atoulx
#define Z "z"
#define ULTYPE unsigned long
#endif
#define ARGS_STEP 512
@ -151,7 +153,7 @@ int config_check_vals(ConfigTable *Conf, ConfigArgs *c, int check_only ) {
int rc, arg_user, arg_type, arg_syn, iarg;
unsigned uiarg;
long larg;
unsigned long ularg;
ULTYPE ularg;
ber_len_t barg;
if(Conf->arg_type == ARG_IGNORED) {

View file

@ -71,7 +71,7 @@ proxyp( ber_socket_t sfd, Sockaddr *from, ber_socklen_t *salen ) {
peername[0] = '\0';
do {
ret = tcp_read( SLAP_FD2SOCK( sfd ), &pph, sizeof(pph) );
ret = tcp_read( SLAP_FD2SOCK( sfd ), (char *)&pph, sizeof(pph) );
} while ( ret == -1 && errno == EINTR );
if ( ret == -1 ) {
@ -127,7 +127,7 @@ proxyp( ber_socket_t sfd, Sockaddr *from, ber_socklen_t *salen ) {
}
do {
ret = tcp_read( SLAP_FD2SOCK (sfd), &ppa, addr_len );
ret = tcp_read( SLAP_FD2SOCK (sfd), (char *)&ppa, addr_len );
} while ( ret == -1 && errno == EINTR );
if ( ret == -1 ) {
@ -204,7 +204,7 @@ proxyp( ber_socket_t sfd, Sockaddr *from, ber_socklen_t *salen ) {
}
do {
ret = tcp_read( SLAP_FD2SOCK (sfd), &proxyp_options, pph_len );
ret = tcp_read( SLAP_FD2SOCK (sfd), (char *)&proxyp_options, pph_len );
} while ( ret == -1 && errno == EINTR );
if ( ret == -1 ) {

View file

@ -1135,7 +1135,7 @@ fork_child( char *prog, char **args )
wait4kids( maxkids );
rc = _spawnvp( _P_NOWAIT, prog, args );
rc = _spawnvp( _P_NOWAIT, prog, (const char *const *)args );
if ( rc == -1 ) {
tester_perror( "_spawnvp", NULL );