From c558bd49bc8776ff686af10741deb572212f4fa8 Mon Sep 17 00:00:00 2001 From: Howard Chu Date: Fri, 5 Mar 2004 12:24:06 +0000 Subject: [PATCH] ITS#2992 Windows fixes from Alexey Melnikov --- build/main.dsw | 105 +++------------------------ include/portable.nt | 1 + libraries/liblber/debug.c | 2 - libraries/libldap/cyrus.c | 2 + libraries/libldap/os-ip.c | 1 - libraries/libldap/search.c | 2 +- libraries/liblutil/liblutil.dsp | 20 +++++ libraries/liblutil/passwd.c | 1 - servers/slapd/back-ldbm/backldbm.dsp | 20 ++--- 9 files changed, 44 insertions(+), 110 deletions(-) diff --git a/build/main.dsw b/build/main.dsw index 49380a9415..6df38c1722 100644 --- a/build/main.dsw +++ b/build/main.dsw @@ -251,9 +251,6 @@ Package=<4> Begin Project Dependency Project_Dep_Name liblutil End Project Dependency - Begin Project Dependency - Project_Dep_Name libldif - End Project Dependency }}} ############################################################################### @@ -294,9 +291,6 @@ Package=<4> Project_Dep_Name liblutil End Project Dependency Begin Project Dependency - Project_Dep_Name libldif - End Project Dependency - Begin Project Dependency Project_Dep_Name liblber End Project Dependency }}} @@ -360,9 +354,6 @@ Package=<4> Project_Dep_Name liblutil End Project Dependency Begin Project Dependency - Project_Dep_Name libldif - End Project Dependency - Begin Project Dependency Project_Dep_Name liblber End Project Dependency }}} @@ -390,21 +381,6 @@ Package=<4> ############################################################################### -Project: "libavl"=..\libraries\libavl\libavl.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ - Begin Project Dependency - Project_Dep_Name setup - End Project Dependency -}}} - -############################################################################### - Project: "liblber"=..\libraries\liblber\liblber.dsp - Package Owner=<4> Package=<5> @@ -450,36 +426,6 @@ Package=<4> ############################################################################### -Project: "libldbm"=..\libraries\libldbm\libldbm.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ - Begin Project Dependency - Project_Dep_Name setup - End Project Dependency -}}} - -############################################################################### - -Project: "libldif"=..\libraries\libldif\libldif.dsp - Package Owner=<4> - -Package=<5> -{{{ -}}} - -Package=<4> -{{{ - Begin Project Dependency - Project_Dep_Name setup - End Project Dependency -}}} - -############################################################################### - Project: "liblunicode"=..\libraries\liblunicode\liblunicode.dsp - Package Owner=<4> Package=<5> @@ -609,21 +555,12 @@ Package=<4> Project_Dep_Name backldbm End Project Dependency Begin Project Dependency - Project_Dep_Name libavl - End Project Dependency - Begin Project Dependency Project_Dep_Name liblber End Project Dependency Begin Project Dependency Project_Dep_Name libldap_r End Project Dependency Begin Project Dependency - Project_Dep_Name libldbm - End Project Dependency - Begin Project Dependency - Project_Dep_Name libldif - End Project Dependency - Begin Project Dependency Project_Dep_Name liblutil End Project Dependency Begin Project Dependency @@ -638,6 +575,9 @@ Package=<4> Begin Project Dependency Project_Dep_Name backmon End Project Dependency + Begin Project Dependency + Project_Dep_Name backldbm + End Project Dependency }}} ############################################################################### @@ -650,9 +590,6 @@ Package=<5> Package=<4> {{{ - Begin Project Dependency - Project_Dep_Name libavl - End Project Dependency Begin Project Dependency Project_Dep_Name liblber End Project Dependency @@ -660,12 +597,6 @@ Package=<4> Project_Dep_Name libldap_r End Project Dependency Begin Project Dependency - Project_Dep_Name libldbm - End Project Dependency - Begin Project Dependency - Project_Dep_Name libldif - End Project Dependency - Begin Project Dependency Project_Dep_Name liblutil End Project Dependency Begin Project Dependency @@ -702,12 +633,6 @@ Package=<4> Project_Dep_Name libldap_r End Project Dependency Begin Project Dependency - Project_Dep_Name libavl - End Project Dependency - Begin Project Dependency - Project_Dep_Name libldif - End Project Dependency - Begin Project Dependency Project_Dep_Name liblutil End Project Dependency Begin Project Dependency @@ -717,9 +642,6 @@ Package=<4> Project_Dep_Name liblber End Project Dependency Begin Project Dependency - Project_Dep_Name libldbm - End Project Dependency - Begin Project Dependency Project_Dep_Name libslapd End Project Dependency Begin Project Dependency @@ -731,6 +653,9 @@ Package=<4> Begin Project Dependency Project_Dep_Name backmon End Project Dependency + Begin Project Dependency + Project_Dep_Name backldbm + End Project Dependency }}} ############################################################################### @@ -747,21 +672,12 @@ Package=<4> Project_Dep_Name backldbm End Project Dependency Begin Project Dependency - Project_Dep_Name libavl - End Project Dependency - Begin Project Dependency Project_Dep_Name liblber End Project Dependency Begin Project Dependency Project_Dep_Name libldap_r End Project Dependency Begin Project Dependency - Project_Dep_Name libldbm - End Project Dependency - Begin Project Dependency - Project_Dep_Name libldif - End Project Dependency - Begin Project Dependency Project_Dep_Name liblutil End Project Dependency Begin Project Dependency @@ -776,11 +692,14 @@ Package=<4> Begin Project Dependency Project_Dep_Name backmon End Project Dependency + Begin Project Dependency + Project_Dep_Name badldbm + End Project Dependency }}} ############################################################################### -Project: "testavl"=..\libraries\libavl\testavl.dsp - Package Owner=<4> +Project: "testavl"=..\libraries\liblutil\testavl.dsp - Package Owner=<4> Package=<5> {{{ @@ -789,10 +708,10 @@ Package=<5> Package=<4> {{{ Begin Project Dependency - Project_Dep_Name libavl + Project_Dep_Name liblber End Project Dependency Begin Project Dependency - Project_Dep_Name liblber + Project_Dep_Name liblutil End Project Dependency }}} diff --git a/include/portable.nt b/include/portable.nt index 460e6482fe..ba60612118 100644 --- a/include/portable.nt +++ b/include/portable.nt @@ -1058,5 +1058,6 @@ typedef signed int ssize_t; #include "ldap_features.h" #include "ac/assert.h" +#include "ac/localize.h" #endif /* _LDAP_PORTABLE_H */ diff --git a/libraries/liblber/debug.c b/libraries/liblber/debug.c index 6a4329562a..69cff09769 100644 --- a/libraries/liblber/debug.c +++ b/libraries/liblber/debug.c @@ -146,8 +146,6 @@ void lutil_log_int( time_t now; struct tm *today; #endif - size_t i; - char * tmp; #ifdef LDAP_SYSLOG /* we're configured to use syslog */ diff --git a/libraries/libldap/cyrus.c b/libraries/libldap/cyrus.c index 8bdfc40fd0..6b3c4c0285 100644 --- a/libraries/libldap/cyrus.c +++ b/libraries/libldap/cyrus.c @@ -632,6 +632,7 @@ ldap_int_sasl_bind( LDAP_FREE( authid.bv_val ); } +#if !defined(_WIN32) /* Check for local */ if ( ldap_pvt_url_scheme2proto( ld->ld_defconn->lconn_server->lud_scheme ) == LDAP_PROTO_IPC ) { char authid[sizeof("uidNumber=4294967295+gidNumber=4294967295," @@ -641,6 +642,7 @@ ldap_int_sasl_bind( (int) geteuid(), (int) getegid() ); (void) ldap_int_sasl_external( ld, ld->ld_defconn, authid, LDAP_PVT_SASL_LOCAL_SSF ); } +#endif /* (re)set security properties */ sasl_setprop( ctx, SASL_SEC_PROPS, diff --git a/libraries/libldap/os-ip.c b/libraries/libldap/os-ip.c index e4cfc0c1f4..1b3b515810 100644 --- a/libraries/libldap/os-ip.c +++ b/libraries/libldap/os-ip.c @@ -523,7 +523,6 @@ ldap_host_connected_to( Sockbuf *sb, const char *host ) struct sockaddr sabuf; #endif struct sockaddr *sa = (struct sockaddr *) &sabuf; - int rc; ber_socket_t sd; (void)memset( (char *)sa, '\0', sizeof sabuf ); diff --git a/libraries/libldap/search.c b/libraries/libldap/search.c index fdbce3d491..aa699ccce9 100644 --- a/libraries/libldap/search.c +++ b/libraries/libldap/search.c @@ -223,7 +223,7 @@ ldap_build_search_req( ber_int_t *idp) { BerElement *ber; - int err, id; + int err; /* * Create the search request. It looks like this: diff --git a/libraries/liblutil/liblutil.dsp b/libraries/liblutil/liblutil.dsp index 22d12140a2..e477ef923b 100644 --- a/libraries/liblutil/liblutil.dsp +++ b/libraries/liblutil/liblutil.dsp @@ -293,5 +293,25 @@ SOURCE=.\utils.c SOURCE=.\uuid.c # End Source File +# Begin Source File + +SOURCE=.\avl.c +# End Source File +# Begin Source File + +SOURCE=..\..\include\avl.h +# End Source File +# Begin Source File + +SOURCE=.\ldif.c +# End Source File +# Begin Source File + +SOURCE=.\fetch.c +# End Source File +# Begin Source File + +SOURCE=..\..\include\ldif.h +# End Source File # End Target # End Project diff --git a/libraries/liblutil/passwd.c b/libraries/liblutil/passwd.c index e6112bd2b7..97f6ed612c 100644 --- a/libraries/liblutil/passwd.c +++ b/libraries/liblutil/passwd.c @@ -185,7 +185,6 @@ int lutil_passwd_add( void lutil_passwd_init() { - struct pw_slist *ptr; struct pw_scheme *s; for( s=(struct pw_scheme *)pw_schemes_default; s->name.bv_val; s++) { diff --git a/servers/slapd/back-ldbm/backldbm.dsp b/servers/slapd/back-ldbm/backldbm.dsp index 65390b2873..2b66e42061 100644 --- a/servers/slapd/back-ldbm/backldbm.dsp +++ b/servers/slapd/back-ldbm/backldbm.dsp @@ -140,10 +140,6 @@ SOURCE=.\attr.c # End Source File # Begin Source File -SOURCE=.\attribute.c -# End Source File -# Begin Source File - SOURCE=".\back-ldbm.h" # End Source File # Begin Source File @@ -196,10 +192,6 @@ SOURCE=.\filterindex.c # End Source File # Begin Source File -SOURCE=.\group.c -# End Source File -# Begin Source File - SOURCE=.\id2children.c # End Source File # Begin Source File @@ -240,10 +232,6 @@ SOURCE=.\operational.c # End Source File # Begin Source File -SOURCE=.\passwd.c -# End Source File -# Begin Source File - SOURCE=".\proto-back-ldbm.h" # End Source File # Begin Source File @@ -258,5 +246,13 @@ SOURCE=.\search.c SOURCE=.\tools.c # End Source File +# Begin Source File + +SOURCE=.\ldbm.c +# End Source File +# Begin Source File + +SOURCE=.\ldbm.h +# End Source File # End Target # End Project -- 2.39.5