diff --git a/include/ac/socket.h b/include/ac/socket.h index 5e20569f54..c1a00456bf 100644 --- a/include/ac/socket.h +++ b/include/ac/socket.h @@ -90,9 +90,9 @@ #undef sock_errno #undef sock_errstr #define sock_errno() WSAGetLastError() -#define sock_errstr(e) WSAGetErrorString(e) +#define sock_errstr(e) ber_pvt_wsa_err2string(e) -LIBLUTIL_F (char *) WSAGetErrorString LDAP_P((int)); +LIBLBER_F (char *) ber_pvt_wsa_err2string LDAP_P((int)); #elif MACOS # define tcp_close( s ) tcpclose( s ) diff --git a/libraries/liblber/Makefile.in b/libraries/liblber/Makefile.in index 227509f974..3c087ae1f5 100644 --- a/libraries/liblber/Makefile.in +++ b/libraries/liblber/Makefile.in @@ -8,10 +8,13 @@ LIBRARY = liblber.la XLIBRARY = ../liblber.a +NT_SRCS = nt_err.c +NT_OBJS = nt_err.lo + SRCS= assert.c decode.c encode.c io.c bprint.c \ - memory.c options.c sockbuf.c + memory.c options.c sockbuf.c $(@PLAT@_SRCS) OBJS= assert.lo decode.lo encode.lo io.lo bprint.lo \ - memory.lo options.lo sockbuf.lo + memory.lo options.lo sockbuf.lo $(@PLAT@_OBJS) XSRCS= version.c PROGRAMS= dtest etest idtest diff --git a/libraries/liblutil/nt_err.c b/libraries/liblber/nt_err.c similarity index 92% rename from libraries/liblutil/nt_err.c rename to libraries/liblber/nt_err.c index 691c19caa6..adb7b97334 100644 --- a/libraries/liblutil/nt_err.c +++ b/libraries/liblber/nt_err.c @@ -11,7 +11,7 @@ #define __RETSTR( x ) case x: return #x; -char *WSAGetErrorString( int err ) +char *ber_pvt_wsa_err2string( int err ) { switch( err ) { @@ -84,13 +84,14 @@ char *WSAGetErrorString( int err ) return "unknown"; } -char *WSAGetLastErrorString( void ) -{ - return WSAGetErrorString( WSAGetLastError() ); -} - #undef __RETSTR +#if 0 /* No one seems to be using these */ +char *ber_pvt_wsa_last_errstring( void ) +{ + return ber_pvt_wsa_err2string( WSAGetLastError() ); +} + char *GetErrorString( int err ) { static char msgBuf[1024]; @@ -108,6 +109,4 @@ char *GetLastErrorString( void ) { return GetErrorString( GetLastError() ); } - - - +#endif diff --git a/libraries/liblutil/Makefile.in b/libraries/liblutil/Makefile.in index 8aec16995f..07cadf5838 100644 --- a/libraries/liblutil/Makefile.in +++ b/libraries/liblutil/Makefile.in @@ -5,8 +5,8 @@ LIBRARY = liblutil.a -NT_SRCS = nt_err.c ntservice.c -NT_OBJS = nt_err.o ntservice.o slapdmsg.res +NT_SRCS = ntservice.c +NT_OBJS = ntservice.o slapdmsg.res UNIX_SRCS = detach.c UNIX_OBJS = detach.o