diff options
author | Stefan Metzmacher <metze@samba.org> | 2009-01-08 12:03:45 +0100 |
---|---|---|
committer | Stefan Metzmacher <metze@samba.org> | 2009-01-08 12:22:21 +0100 |
commit | 3dde0cbb769b92d922be13677ad076cae9b6a693 (patch) | |
tree | 78594e39465f545c7252eaef7bc469ceb80c4d71 /source3/smbd/dir.c | |
parent | defb574c2573a73335a2735e89e4cb5f96c4c069 (diff) | |
download | samba-3dde0cbb769b92d922be13677ad076cae9b6a693.tar.gz samba-3dde0cbb769b92d922be13677ad076cae9b6a693.tar.xz samba-3dde0cbb769b92d922be13677ad076cae9b6a693.zip |
s3:smbd: move all globals and static variables in globals.[ch]
The goal is to move all this variables into a big context structure.
metze
Diffstat (limited to 'source3/smbd/dir.c')
-rw-r--r-- | source3/smbd/dir.c | 10 |
1 files changed, 2 insertions, 8 deletions
diff --git a/source3/smbd/dir.c b/source3/smbd/dir.c index c2735c032a7..2b996a41cfd 100644 --- a/source3/smbd/dir.c +++ b/source3/smbd/dir.c @@ -19,6 +19,7 @@ */ #include "includes.h" +#include "smbd/globals.h" /* This module implements directory related functions for Samba. @@ -61,9 +62,6 @@ struct dptr_struct { bool did_stat; /* Optimisation for non-wcard searches. */ }; -static struct bitmap *dptr_bmap; -static struct dptr_struct *dirptrs; -static int dirhandles_open = 0; #define INVALID_DPTR_KEY (-3) @@ -119,17 +117,13 @@ bool make_dir_struct(TALLOC_CTX *ctx, void init_dptrs(void) { - static bool dptrs_init=False; - - if (dptrs_init) + if (dptr_bmap) return; dptr_bmap = bitmap_allocate(MAX_DIRECTORY_HANDLES); if (!dptr_bmap) exit_server("out of memory in init_dptrs"); - - dptrs_init = True; } /**************************************************************************** |