]> git.sur5r.net Git - openldap/blobdiff - servers/slapd/back-ldbm/startup.c
Removed unnecessary definition that is already in core.schema.
[openldap] / servers / slapd / back-ldbm / startup.c
index 2b52a07ecceb2573f7325fb871aeee513c5b6afc..972ea04725414e8ba335ce642403abccf88e3d3b 100644 (file)
@@ -3,6 +3,7 @@
 #include "portable.h"
 
 #include <stdio.h>
+#include <direct.h>
 
 #include <ac/string.h>
 #include <ac/socket.h>
 #include "slap.h"
 #include "back-ldbm.h"
 
-#include "db.h"
+#ifdef HAVE_DB1_DB_H
+#      include <db1/db.h>
+#else
+#      include <db.h>
+#endif
+
+#ifdef HAVE_BERKELEY_DB2
+
+void
+ldbm_db_errcall( const char *prefix, const char *message )
+{
+       Debug( LDAP_DEBUG_ANY, "ldbm_db_errcall(): %s %s", prefix, message, 0 );
+}
+
+#endif  /*  HAVE_BERKELEY_DB2  */
 
 
 void
@@ -36,11 +51,11 @@ ldbm_back_startup(
 
        /*  if the data directory is not an absolute path, have it relative
         to the current working directory (which should not be configured !)  */
-       if ( *li->li_directory != *DEFAULT_DIRSEP ) {
+       if ( *li->li_directory != *DIRSEP ) {
                char   cwd[MAXPATHLEN];
 
                (void) getcwd( cwd, MAXPATHLEN );
-               sprintf( cwd, "%s%s%s", cwd, DEFAULT_DIRSEP, li->li_directory );
+               sprintf( cwd, "%s%s%s", cwd, DIRSEP, li->li_directory );
                free( li->li_directory );
                li->li_directory = strdup( cwd );
 
@@ -82,15 +97,3 @@ ldbm_back_shutdown(
        (void) db_appexit( &li->li_db_env );
 #endif
 }
-
-
-#ifdef HAVE_BERKELEY_DB2
-
-void
-ldbm_db_errcall( const char *prefix, char *message )
-{
-       Debug( LDAP_DEBUG_ANY, "ldbm_db_errcall(): %s %s", prefix, message, 0 );
-}
-
-#endif  /*  HAVE_BERKELEY_DB2  */
-