if the stat cache is off then don't initialise it
authorAndrew Tridgell <tridge@samba.org>
Thu, 4 May 2000 06:28:38 +0000 (06:28 +0000)
committerAndrew Tridgell <tridge@samba.org>
Thu, 4 May 2000 06:28:38 +0000 (06:28 +0000)
source/smbd/statcache.c

index e0ceddff1da82c94a18222692e3ad3fc5d23846e..7b8701337ff61b7d4e99ef52cd3407ddb7252ecf 100644 (file)
@@ -240,6 +240,8 @@ BOOL stat_cache_lookup(connection_struct *conn, char *name, char *dirpath,
 BOOL reset_stat_cache( void )
 {
        static BOOL initialised;
+       if (!lp_stat_cache()) return True;
+
        if (!initialised) {
                initialised = True;
                return hash_table_init( &stat_cache, INIT_STAT_CACHE_SIZE, (compare_function)(strcmp));