FD_CLR( writefds.fd_array[i], &readfds );
slapd_close( writefds.fd_array[i] );
}
+ }
#else
for ( i = 0; i < nfds; i++ ) {
if ( i == tcps ) {
slapd_close( i );
}
}
+ }
#endif
- }
#ifdef HAVE_WINSOCK
for ( i = 0; i < readfds.fd_count; i++ ) {
if ( readfds.fd_array[i] == tcps ) {
switch ( i ) {
case 'a': /* bind address */
#ifdef HAVE_WINSOCK
- if(!(bind_addr.sin_addr.S_un.S_addr = inet_addr(optarg))) {
+ if(!(bind_addr.sin_addr.S_un.S_addr = inet_addr(optarg)))
#else
- if(!inet_aton(optarg, &bind_addr.sin_addr)) {
+ if(!inet_aton(optarg, &bind_addr.sin_addr))
#endif
+ {
fprintf(stderr, "invalid address (%s) for -a option", optarg);
}
break;
fclose( fp );
#ifdef HAVE_WAITPID
- if ( waitpid( (pid_t) -1, NULL, WAIT_FLAGS ) < 0 ) {
+ if ( waitpid( (pid_t) -1, NULL, WAIT_FLAGS ) < 0 )
#else
- if ( wait4( (pid_t) -1, &status, WAIT_FLAGS, 0 ) < 0 ) {
+ if ( wait3( (pid_t) -1, &status, WAIT_FLAGS, 0 ) < 0 )
#endif
+ {
perror( "wait" );
return;
}