Commit 67d005ee authored by Ondřej Kuzník's avatar Ondřej Kuzník
Browse files

ITS#9348 Stop using plain strerror()

parent f3e86d3d
...@@ -168,8 +168,10 @@ static int dsaschema_read_config(const char *fname, int depth) ...@@ -168,8 +168,10 @@ static int dsaschema_read_config(const char *fname, int depth)
fp = fopen(fname, "r"); fp = fopen(fname, "r");
if (fp == NULL) { if (fp == NULL) {
char ebuf[128];
int saved_errno = errno;
fprintf(stderr, "could not open config file \"%s\": %s (%d)\n", fprintf(stderr, "could not open config file \"%s\": %s (%d)\n",
fname, strerror(errno), errno); fname, AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)), saved_errno);
return 1; return 1;
} }
fp_getline_init(&lineno); fp_getline_init(&lineno);
......
...@@ -86,8 +86,10 @@ static void debug_dump(const void *ptr, size_t size) ...@@ -86,8 +86,10 @@ static void debug_dump(const void *ptr, size_t size)
DEBUG_DUMP(ptr, size); \ DEBUG_DUMP(ptr, size); \
if (tio_write(fp, ptr, (size_t)size)) \ if (tio_write(fp, ptr, (size_t)size)) \
{ \ { \
char ebuf[128]; \
int saved_errno = errno; \
DEBUG_PRINT("WRITE : var="__STRING(ptr)" error: %s", \ DEBUG_PRINT("WRITE : var="__STRING(ptr)" error: %s", \
strerror(errno)); \ AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf))); \
ERROR_OUT_WRITEERROR(fp); \ ERROR_OUT_WRITEERROR(fp); \
} }
...@@ -161,8 +163,10 @@ static void debug_dump(const void *ptr, size_t size) ...@@ -161,8 +163,10 @@ static void debug_dump(const void *ptr, size_t size)
#define READ(fp, ptr, size) \ #define READ(fp, ptr, size) \
if (tio_read(fp, ptr, (size_t)size)) \ if (tio_read(fp, ptr, (size_t)size)) \
{ \ { \
char ebuf[128]; \
int saved_errno = errno; \
DEBUG_PRINT("READ : var="__STRING(ptr)" error: %s", \ DEBUG_PRINT("READ : var="__STRING(ptr)" error: %s", \
strerror(errno)); \ AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf))); \
ERROR_OUT_READERROR(fp); \ ERROR_OUT_READERROR(fp); \
} \ } \
DEBUG_PRINT("READ : var="__STRING(ptr)" size=%d", (int)(size)); \ DEBUG_PRINT("READ : var="__STRING(ptr)" size=%d", (int)(size)); \
...@@ -301,7 +305,10 @@ static void debug_dump(const void *ptr, size_t size) ...@@ -301,7 +305,10 @@ static void debug_dump(const void *ptr, size_t size)
/* read (skip) the specified number of bytes */ \ /* read (skip) the specified number of bytes */ \
if (tio_skip(fp, sz)) \ if (tio_skip(fp, sz)) \
{ \ { \
DEBUG_PRINT("READ : skip error: %s", strerror(errno)); \ char ebuf[128]; \
int saved_errno = errno; \
DEBUG_PRINT("READ : skip error: %s", \
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf))); \
ERROR_OUT_READERROR(fp); \ ERROR_OUT_READERROR(fp); \
} }
...@@ -350,7 +357,10 @@ TFILE *nslcd_client_open(void) ...@@ -350,7 +357,10 @@ TFILE *nslcd_client_open(void)
/* flush the stream */ \ /* flush the stream */ \
if (tio_flush(fp) < 0) \ if (tio_flush(fp) < 0) \
{ \ { \
DEBUG_PRINT("WRITE_FLUSH : error: %s", strerror(errno)); \ char ebuf[128]; \
int saved_errno = errno; \
DEBUG_PRINT("WRITE_FLUSH : error: %s", \
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf))); \
ERROR_OUT_WRITEERROR(fp); \ ERROR_OUT_WRITEERROR(fp); \
} \ } \
/* read and check response version number */ \ /* read and check response version number */ \
......
...@@ -298,11 +298,15 @@ static void handleconnection(nssov_info *ni,int sock,Operation *op) ...@@ -298,11 +298,15 @@ static void handleconnection(nssov_info *ni,int sock,Operation *op)
struct berval peerbv = { sizeof(peerbuf), peerbuf }; struct berval peerbv = { sizeof(peerbuf), peerbuf };
/* log connection */ /* log connection */
if (LUTIL_GETPEEREID(sock,&uid,&gid,&peerbv)) if (LUTIL_GETPEEREID(sock,&uid,&gid,&peerbv)) {
Debug( LDAP_DEBUG_TRACE,"nssov: connection from unknown client: %s\n",strerror(errno) ); char ebuf[128];
else int saved_errno = errno;
Debug( LDAP_DEBUG_TRACE,"nssov: connection from unknown client: %s\n",
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
} else {
Debug( LDAP_DEBUG_TRACE,"nssov: connection from uid=%d gid=%d\n", Debug( LDAP_DEBUG_TRACE,"nssov: connection from uid=%d gid=%d\n",
(int)uid,(int)gid ); (int)uid,(int)gid );
}
/* Should do authid mapping too */ /* Should do authid mapping too */
op->o_dn.bv_len = sprintf(authid,"gidNumber=%d+uidNumber=%d,cn=peercred,cn=external,cn=auth", op->o_dn.bv_len = sprintf(authid,"gidNumber=%d+uidNumber=%d,cn=peercred,cn=external,cn=auth",
...@@ -322,7 +326,10 @@ static void handleconnection(nssov_info *ni,int sock,Operation *op) ...@@ -322,7 +326,10 @@ static void handleconnection(nssov_info *ni,int sock,Operation *op)
READBUFFER_MINSIZE,READBUFFER_MAXSIZE, READBUFFER_MINSIZE,READBUFFER_MAXSIZE,
WRITEBUFFER_MINSIZE,WRITEBUFFER_MAXSIZE))==NULL) WRITEBUFFER_MINSIZE,WRITEBUFFER_MAXSIZE))==NULL)
{ {
Debug( LDAP_DEBUG_ANY,"nssov: cannot create stream for writing: %s",strerror(errno) ); char ebuf[128];
int saved_errno = errno;
Debug( LDAP_DEBUG_ANY,"nssov: cannot create stream for writing: %s",
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
(void)close(sock); (void)close(sock);
return; return;
} }
...@@ -403,27 +410,43 @@ static void *acceptconn(void *ctx, void *arg) ...@@ -403,27 +410,43 @@ static void *acceptconn(void *ctx, void *arg)
connection_client_enable(ni->ni_conn); connection_client_enable(ni->ni_conn);
if (csock<0) if (csock<0)
{ {
char ebuf[128];
int saved_errno = errno;
if ((errno==EINTR)||(errno==EAGAIN)||(errno==EWOULDBLOCK)) if ((errno==EINTR)||(errno==EAGAIN)||(errno==EWOULDBLOCK))
{ {
Debug( LDAP_DEBUG_TRACE,"nssov: accept() failed (ignored): %s",strerror(errno) ); Debug( LDAP_DEBUG_TRACE,"nssov: accept() failed (ignored): %s",
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
return NULL; return NULL;
} }
Debug( LDAP_DEBUG_ANY,"nssov: accept() failed: %s",strerror(errno) ); Debug( LDAP_DEBUG_ANY,"nssov: accept() failed: %s",
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
return NULL; return NULL;
} }
/* make sure O_NONBLOCK is not inherited */ /* make sure O_NONBLOCK is not inherited */
if ((j=fcntl(csock,F_GETFL,0))<0) if ((j=fcntl(csock,F_GETFL,0))<0)
{ {
Debug( LDAP_DEBUG_ANY,"nssov: fcntl(F_GETFL) failed: %s",strerror(errno) ); char ebuf[128];
if (close(csock)) int saved_errno = errno;
Debug( LDAP_DEBUG_ANY,"nssov: problem closing socket: %s",strerror(errno) ); Debug( LDAP_DEBUG_ANY,"nssov: fcntl(F_GETFL) failed: %s",
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
if (close(csock)) {
saved_errno = errno;
Debug( LDAP_DEBUG_ANY,"nssov: problem closing socket: %s",
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
}
return NULL; return NULL;
} }
if (fcntl(csock,F_SETFL,j&~O_NONBLOCK)<0) if (fcntl(csock,F_SETFL,j&~O_NONBLOCK)<0)
{ {
Debug( LDAP_DEBUG_ANY,"nssov: fcntl(F_SETFL,~O_NONBLOCK) failed: %s",strerror(errno) ); char ebuf[128];
if (close(csock)) int saved_errno = errno;
Debug( LDAP_DEBUG_ANY,"nssov: problem closing socket: %s",strerror(errno) ); Debug( LDAP_DEBUG_ANY,"nssov: fcntl(F_SETFL,~O_NONBLOCK) failed: %s",
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
if (close(csock)) {
saved_errno = errno;
Debug( LDAP_DEBUG_ANY,"nssov: problem closing socket: %s",
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
}
return NULL; return NULL;
} }
} }
...@@ -868,10 +891,12 @@ nssov_db_open( ...@@ -868,10 +891,12 @@ nssov_db_open(
} }
} }
if ( slapMode & SLAP_SERVER_MODE ) { if ( slapMode & SLAP_SERVER_MODE ) {
char ebuf[128];
/* make sure /var/run/nslcd exists */ /* make sure /var/run/nslcd exists */
if (mkdir(NSLCD_PATH, (mode_t) 0555)) { if (mkdir(NSLCD_PATH, (mode_t) 0555)) {
int saved_errno = errno;
Debug(LDAP_DEBUG_TRACE,"nssov: mkdir(%s) failed (ignored): %s\n", Debug(LDAP_DEBUG_TRACE,"nssov: mkdir(%s) failed (ignored): %s\n",
NSLCD_PATH,strerror(errno) ); NSLCD_PATH, AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
} else { } else {
Debug(LDAP_DEBUG_TRACE,"nssov: created %s\n",NSLCD_PATH ); Debug(LDAP_DEBUG_TRACE,"nssov: created %s\n",NSLCD_PATH );
} }
...@@ -879,14 +904,17 @@ nssov_db_open( ...@@ -879,14 +904,17 @@ nssov_db_open(
/* create a socket */ /* create a socket */
if ( (sock=socket(PF_UNIX,SOCK_STREAM,0))<0 ) if ( (sock=socket(PF_UNIX,SOCK_STREAM,0))<0 )
{ {
Debug(LDAP_DEBUG_ANY,"nssov: cannot create socket: %s\n",strerror(errno) ); int saved_errno = errno;
Debug(LDAP_DEBUG_ANY,"nssov: cannot create socket: %s\n",
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
return -1; return -1;
} }
/* remove existing named socket */ /* remove existing named socket */
if (unlink(NSLCD_SOCKET)<0) if (unlink(NSLCD_SOCKET)<0)
{ {
int saved_errno = errno;
Debug( LDAP_DEBUG_TRACE,"nssov: unlink() of "NSLCD_SOCKET" failed (ignored): %s\n", Debug( LDAP_DEBUG_TRACE,"nssov: unlink() of "NSLCD_SOCKET" failed (ignored): %s\n",
strerror(errno) ); AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
} }
/* create socket address structure */ /* create socket address structure */
memset(&addr,0,sizeof(struct sockaddr_un)); memset(&addr,0,sizeof(struct sockaddr_un));
...@@ -896,18 +924,27 @@ nssov_db_open( ...@@ -896,18 +924,27 @@ nssov_db_open(
/* bind to the named socket */ /* bind to the named socket */
if (bind(sock,(struct sockaddr *)&addr,sizeof(struct sockaddr_un))) if (bind(sock,(struct sockaddr *)&addr,sizeof(struct sockaddr_un)))
{ {
int saved_errno = errno;
Debug( LDAP_DEBUG_ANY,"nssov: bind() to "NSLCD_SOCKET" failed: %s", Debug( LDAP_DEBUG_ANY,"nssov: bind() to "NSLCD_SOCKET" failed: %s",
strerror(errno) ); AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
if (close(sock)) if (close(sock)) {
Debug( LDAP_DEBUG_ANY,"nssov: problem closing socket: %s",strerror(errno) ); saved_errno = errno
Debug( LDAP_DEBUG_ANY,"nssov: problem closing socket: %s",
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
}
return -1; return -1;
} }
/* close the file descriptor on exit */ /* close the file descriptor on exit */
if (fcntl(sock,F_SETFD,FD_CLOEXEC)<0) if (fcntl(sock,F_SETFD,FD_CLOEXEC)<0)
{ {
Debug( LDAP_DEBUG_ANY,"nssov: fcntl(F_SETFL,O_NONBLOCK) failed: %s",strerror(errno) ); int saved_errno = errno;
if (close(sock)) Debug( LDAP_DEBUG_ANY,"nssov: fcntl(F_SETFL,O_NONBLOCK) failed: %s",
Debug( LDAP_DEBUG_ANY,"nssov: problem closing socket: %s",strerror(errno) ); AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
if (close(sock)) {
saved_errno = errno
Debug( LDAP_DEBUG_ANY,"nssov: problem closing socket: %s",
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
}
return -1; return -1;
} }
/* set permissions of socket so anybody can do requests */ /* set permissions of socket so anybody can do requests */
...@@ -917,17 +954,27 @@ nssov_db_open( ...@@ -917,17 +954,27 @@ nssov_db_open(
http://lkml.org/lkml/2005/5/16/11 */ http://lkml.org/lkml/2005/5/16/11 */
if (chmod(NSLCD_SOCKET,(mode_t)0666)) if (chmod(NSLCD_SOCKET,(mode_t)0666))
{ {
Debug( LDAP_DEBUG_ANY,"nssov: chmod(0666) failed: %s",strerror(errno) ); int saved_errno = errno;
if (close(sock)) Debug( LDAP_DEBUG_ANY,"nssov: chmod(0666) failed: %s",
Debug( LDAP_DEBUG_ANY,"nssov: problem closing socket: %s",strerror(errno) ); AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
if (close(sock)) {
saved_errno = errno
Debug( LDAP_DEBUG_ANY,"nssov: problem closing socket: %s",
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
}
return -1; return -1;
} }
/* start listening for connections */ /* start listening for connections */
if (listen(sock,SOMAXCONN)<0) if (listen(sock,SOMAXCONN)<0)
{ {
Debug( LDAP_DEBUG_ANY,"nssov: listen() failed: %s",strerror(errno) ); int saved_errno = errno;
if (close(sock)) Debug( LDAP_DEBUG_ANY,"nssov: listen() failed: %s",
Debug( LDAP_DEBUG_ANY,"nssov: problem closing socket: %s",strerror(errno) ); AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
if (close(sock)) {
saved_errno = errno
Debug( LDAP_DEBUG_ANY,"nssov: problem closing socket: %s",
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
}
return -1; return -1;
} }
ni->ni_socket = sock; ni->ni_socket = sock;
...@@ -946,18 +993,23 @@ nssov_db_close( ...@@ -946,18 +993,23 @@ nssov_db_close(
nssov_info *ni = on->on_bi.bi_private; nssov_info *ni = on->on_bi.bi_private;
if ( slapMode & SLAP_SERVER_MODE ) { if ( slapMode & SLAP_SERVER_MODE ) {
char ebuf[128];
/* close socket if it's still in use */ /* close socket if it's still in use */
if (ni->ni_socket >= 0) if (ni->ni_socket >= 0)
{ {
if (close(ni->ni_socket)) if (close(ni->ni_socket)) {
Debug( LDAP_DEBUG_ANY,"problem closing server socket (ignored): %s",strerror(errno) ); int saved_errno = errno;
Debug( LDAP_DEBUG_ANY,"problem closing server socket (ignored): %s",
AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
}
ni->ni_socket = -1; ni->ni_socket = -1;
} }
/* remove existing named socket */ /* remove existing named socket */
if (unlink(NSLCD_SOCKET)<0) if (unlink(NSLCD_SOCKET)<0)
{ {
int saved_errno = errno;
Debug( LDAP_DEBUG_TRACE,"unlink() of "NSLCD_SOCKET" failed (ignored): %s", Debug( LDAP_DEBUG_TRACE,"unlink() of "NSLCD_SOCKET" failed (ignored): %s",
strerror(errno) ); AC_STRERROR_R(saved_errno, ebuf, sizeof(ebuf)) );
} }
} }
return 0; return 0;
......
...@@ -1143,9 +1143,11 @@ file2anlist( AttributeName *an, const char *fname, const char *brkstr ) ...@@ -1143,9 +1143,11 @@ file2anlist( AttributeName *an, const char *fname, const char *brkstr )
fp = fopen( fname, "r" ); fp = fopen( fname, "r" );
if ( fp == NULL ) { if ( fp == NULL ) {
char ebuf[128];
int saved_errno = errno;
Debug( LDAP_DEBUG_ANY, Debug( LDAP_DEBUG_ANY,
"get_attrs_from_file: failed to open attribute list file " "get_attrs_from_file: failed to open attribute list file "
"\"%s\": %s\n", fname, strerror(errno) ); "\"%s\": %s\n", fname, AC_STRERROR_R( saved_errno, ebuf, sizeof(ebuf) ) );
return NULL; return NULL;
} }
......
...@@ -700,8 +700,10 @@ mdb_cf_gen( ConfigArgs *c ) ...@@ -700,8 +700,10 @@ mdb_cf_gen( ConfigArgs *c )
} }
ch_free( testpath ); ch_free( testpath );
if ( !f ) { if ( !f ) {
char ebuf[128];
int saved_errno = errno;
snprintf( c->cr_msg, sizeof( c->cr_msg ), "%s: invalid path: %s", snprintf( c->cr_msg, sizeof( c->cr_msg ), "%s: invalid path: %s",
c->log, strerror( errno )); c->log, AC_STRERROR_R( saved_errno, ebuf, sizeof(ebuf) ) );
Debug( LDAP_DEBUG_ANY, "%s\n", c->cr_msg ); Debug( LDAP_DEBUG_ANY, "%s\n", c->cr_msg );
return -1; return -1;
} }
......
...@@ -787,11 +787,12 @@ read_config_file(const char *fname, int depth, ConfigArgs *cf, ConfigTable *cft) ...@@ -787,11 +787,12 @@ read_config_file(const char *fname, int depth, ConfigArgs *cf, ConfigTable *cft)
init_config_argv( c ); init_config_argv( c );
if ( stat( fname, &s ) != 0 ) { if ( stat( fname, &s ) != 0 ) {
char ebuf[128];
int saved_errno = errno; int saved_errno = errno;
ldap_syslog = 1; ldap_syslog = 1;
Debug(LDAP_DEBUG_ANY, Debug(LDAP_DEBUG_ANY,
"could not stat config file \"%s\": %s (%d)\n", "could not stat config file \"%s\": %s (%d)\n",
fname, strerror(saved_errno), saved_errno); fname, AC_STRERROR_R( saved_errno, ebuf, sizeof(ebuf) ), saved_errno);
ch_free( c->argv ); ch_free( c->argv );
ch_free( c ); ch_free( c );
return(1); return(1);
...@@ -809,11 +810,12 @@ read_config_file(const char *fname, int depth, ConfigArgs *cf, ConfigTable *cft) ...@@ -809,11 +810,12 @@ read_config_file(const char *fname, int depth, ConfigArgs *cf, ConfigTable *cft)
fp = fopen( fname, "r" ); fp = fopen( fname, "r" );
if ( fp == NULL ) { if ( fp == NULL ) {
char ebuf[128];
int saved_errno = errno; int saved_errno = errno;
ldap_syslog = 1; ldap_syslog = 1;
Debug(LDAP_DEBUG_ANY, Debug(LDAP_DEBUG_ANY,
"could not open config file \"%s\": %s (%d)\n", "could not open config file \"%s\": %s (%d)\n",
fname, strerror(saved_errno), saved_errno); fname, AC_STRERROR_R( saved_errno, ebuf, sizeof(ebuf) ), saved_errno);
ch_free( c->argv ); ch_free( c->argv );
ch_free( c ); ch_free( c );
return(1); return(1);
......
...@@ -945,12 +945,13 @@ unhandled_option:; ...@@ -945,12 +945,13 @@ unhandled_option:;
FILE *fp = fopen( slapd_pid_file, "w" ); FILE *fp = fopen( slapd_pid_file, "w" );
if ( fp == NULL ) { if ( fp == NULL ) {
char ebuf[128];
int save_errno = errno; int save_errno = errno;
Debug( LDAP_DEBUG_ANY, "unable to open pid file " Debug( LDAP_DEBUG_ANY, "unable to open pid file "
"\"%s\": %d (%s)\n", "\"%s\": %d (%s)\n",
slapd_pid_file, slapd_pid_file,
save_errno, strerror( save_errno ) ); save_errno, AC_STRERROR_R( save_errno, ebuf, sizeof(ebuf) ) );
free( slapd_pid_file ); free( slapd_pid_file );
slapd_pid_file = NULL; slapd_pid_file = NULL;
...@@ -967,12 +968,13 @@ unhandled_option:; ...@@ -967,12 +968,13 @@ unhandled_option:;
FILE *fp = fopen( slapd_args_file, "w" ); FILE *fp = fopen( slapd_args_file, "w" );
if ( fp == NULL ) { if ( fp == NULL ) {
char ebuf[128];
int save_errno = errno; int save_errno = errno;
Debug( LDAP_DEBUG_ANY, "unable to open args file " Debug( LDAP_DEBUG_ANY, "unable to open args file "
"\"%s\": %d (%s)\n", "\"%s\": %d (%s)\n",
slapd_args_file, slapd_args_file,
save_errno, strerror( save_errno ) ); save_errno, AC_STRERROR_R( save_errno, ebuf, sizeof(ebuf) ) );
free( slapd_args_file ); free( slapd_args_file );
slapd_args_file = NULL; slapd_args_file = NULL;
......
...@@ -46,6 +46,7 @@ static int ...@@ -46,6 +46,7 @@ static int
test_file( const char *fname, const char *ftype ) test_file( const char *fname, const char *ftype )
{ {
struct stat st; struct stat st;
char ebuf[128];
int save_errno; int save_errno;
switch ( stat( fname, &st ) ) { switch ( stat( fname, &st ) ) {
...@@ -70,7 +71,7 @@ test_file( const char *fname, const char *ftype ) ...@@ -70,7 +71,7 @@ test_file( const char *fname, const char *ftype )
Debug( LDAP_DEBUG_ANY, "unable to open file " Debug( LDAP_DEBUG_ANY, "unable to open file "
"\"%s\": %d (%s)\n", "\"%s\": %d (%s)\n",
fname, fname,
save_errno, strerror( save_errno ) ); save_errno, AC_STRERROR_R( save_errno, ebuf, sizeof(ebuf) ) );
return -1; return -1;
} }
...@@ -82,7 +83,7 @@ test_file( const char *fname, const char *ftype ) ...@@ -82,7 +83,7 @@ test_file( const char *fname, const char *ftype )
Debug( LDAP_DEBUG_ANY, "unable to stat file " Debug( LDAP_DEBUG_ANY, "unable to stat file "
"\"%s\": %d (%s)\n", "\"%s\": %d (%s)\n",
slapd_pid_file, slapd_pid_file,
save_errno, strerror( save_errno ) ); save_errno, AC_STRERROR_R( save_errno, ebuf, sizeof(ebuf) ) );
return -1; return -1;
} }
......
Markdown is supported
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment