]> git.sur5r.net Git - openldap/blobdiff - libraries/libldbm/ldbm.c
Provide a little information about SDF, how to use it, and where to get it.h
[openldap] / libraries / libldbm / ldbm.c
index 678a7e5b3e9480c14d75e5ce6053ea7df129fbb7..0ce41481c8213a876c0c8826c69fa0edce2b1e47 100644 (file)
@@ -426,6 +426,9 @@ LDBM
 ldbm_open( char *name, int rw, int mode, int dbcachesize )
 {
        LDBM            db;
+#ifdef HAVE_ST_BLKSIZE
+               struct stat     st;
+#endif
 
        LDBM_LOCK;
 
@@ -436,7 +439,6 @@ ldbm_open( char *name, int rw, int mode, int dbcachesize )
 
 #ifdef HAVE_ST_BLKSIZE
        if ( dbcachesize > 0 && stat( name, &st ) == 0 ) {
-               struct stat     st;
                dbcachesize = (dbcachesize / st.st_blksize);
                gdbm_setopt( db, GDBM_CACHESIZE, &dbcachesize, sizeof(int) );
        }