summaryrefslogtreecommitdiff
path: root/source3/nsswitch
diff options
context:
space:
mode:
authorHerb Lewis <herb@samba.org>2006-12-12 17:38:42 +0000
committerGerald (Jerry) Carter <jerry@samba.org>2007-10-10 12:16:26 -0500
commit791f48f167de339c8ae371e5c80706511fd10018 (patch)
treede938796cdcc79502b4c8257b9239e5f5070051f /source3/nsswitch
parent243b462b094f80d89020bdad78a531a857281bad (diff)
downloadsamba-791f48f167de339c8ae371e5c80706511fd10018.tar.gz
samba-791f48f167de339c8ae371e5c80706511fd10018.tar.bz2
samba-791f48f167de339c8ae371e5c80706511fd10018.zip
r20124: clean up nested extern declaration warnings
(This used to be commit ac3eb7813e33b9a2e78c9158433f7ed62c3b62bb)
Diffstat (limited to 'source3/nsswitch')
-rw-r--r--source3/nsswitch/winbindd_ads.c3
-rw-r--r--source3/nsswitch/winbindd_cache.c13
-rw-r--r--source3/nsswitch/winbindd_cm.c3
-rw-r--r--source3/nsswitch/winbindd_dual.c3
-rw-r--r--source3/nsswitch/winbindd_util.c6
5 files changed, 15 insertions, 13 deletions
diff --git a/source3/nsswitch/winbindd_ads.c b/source3/nsswitch/winbindd_ads.c
index ad24b87a90..3505f183f2 100644
--- a/source3/nsswitch/winbindd_ads.c
+++ b/source3/nsswitch/winbindd_ads.c
@@ -30,6 +30,8 @@
#undef DBGC_CLASS
#define DBGC_CLASS DBGC_WINBIND
+extern struct winbindd_methods reconnect_methods;
+
/*
return our ads connections structure for a domain. We keep the connection
open to make things faster
@@ -117,7 +119,6 @@ static ADS_STRUCT *ads_cached_connection(struct winbindd_domain *domain)
server, fall back to MSRPC */
if (status.error_type == ENUM_ADS_ERROR_SYSTEM &&
status.err.rc == ECONNREFUSED) {
- extern struct winbindd_methods reconnect_methods;
/* 'reconnect_methods' is the MS-RPC backend. */
DEBUG(1,("Trying MSRPC methods\n"));
domain->backend = &reconnect_methods;
diff --git a/source3/nsswitch/winbindd_cache.c b/source3/nsswitch/winbindd_cache.c
index 7990068ee4..0587d8b2b3 100644
--- a/source3/nsswitch/winbindd_cache.c
+++ b/source3/nsswitch/winbindd_cache.c
@@ -29,6 +29,12 @@
#undef DBGC_CLASS
#define DBGC_CLASS DBGC_WINBIND
+extern struct winbindd_methods reconnect_methods;
+extern BOOL opt_nocache;
+#ifdef HAVE_ADS
+extern struct winbindd_methods ads_methods;
+#endif
+
/* Global online/offline state - False when online. winbindd starts up online
and sets this to true if the first query fails and there's an entry in
the cache tdb telling us to stay offline. */
@@ -112,10 +118,7 @@ static struct winbind_cache *get_cache(struct winbindd_domain *domain)
*/
if (!domain->backend) {
- extern struct winbindd_methods reconnect_methods;
#ifdef HAVE_ADS
- extern struct winbindd_methods ads_methods;
-
/* find our domain first so we can figure out if we
are joined to a kerberized domain */
@@ -558,8 +561,6 @@ static struct cache_entry *wcache_fetch(struct winbind_cache *cache,
char *kstr;
struct cache_entry *centry;
- extern BOOL opt_nocache;
-
if (opt_nocache) {
return NULL;
}
@@ -2359,8 +2360,6 @@ static int traverse_fn_cleanup(TDB_CONTEXT *the_tdb, TDB_DATA kbuf,
/* flush the cache */
void wcache_flush_cache(void)
{
- extern BOOL opt_nocache;
-
if (!wcache)
return;
if (wcache->tdb) {
diff --git a/source3/nsswitch/winbindd_cm.c b/source3/nsswitch/winbindd_cm.c
index 2c341d5efa..c0a6aeb85d 100644
--- a/source3/nsswitch/winbindd_cm.c
+++ b/source3/nsswitch/winbindd_cm.c
@@ -65,6 +65,8 @@
#undef DBGC_CLASS
#define DBGC_CLASS DBGC_WINBIND
+extern struct winbindd_methods reconnect_methods;
+
static NTSTATUS init_dc_connection_network(struct winbindd_domain *domain);
static void set_dc_type_and_flags( struct winbindd_domain *domain );
@@ -196,7 +198,6 @@ void set_domain_offline(struct winbindd_domain *domain)
static void set_domain_online(struct winbindd_domain *domain)
{
- extern struct winbindd_methods reconnect_methods;
struct timeval now;
DEBUG(10,("set_domain_online: called for domain %s\n",
diff --git a/source3/nsswitch/winbindd_dual.c b/source3/nsswitch/winbindd_dual.c
index 71ab7a1ae2..70af8333c5 100644
--- a/source3/nsswitch/winbindd_dual.c
+++ b/source3/nsswitch/winbindd_dual.c
@@ -34,6 +34,8 @@
#undef DBGC_CLASS
#define DBGC_CLASS DBGC_WINBIND
+extern BOOL override_logfile;
+
/* Read some data from a client connection */
static void child_read_request(struct winbindd_cli_state *state)
@@ -759,7 +761,6 @@ static BOOL fork_domain_child(struct winbindd_child *child)
int fdpair[2];
struct winbindd_cli_state state;
struct winbindd_domain *domain;
- extern BOOL override_logfile;
if (socketpair(AF_UNIX, SOCK_STREAM, 0, fdpair) != 0) {
DEBUG(0, ("Could not open child pipe: %s\n",
diff --git a/source3/nsswitch/winbindd_util.c b/source3/nsswitch/winbindd_util.c
index c0a19cd36f..e4b51019aa 100644
--- a/source3/nsswitch/winbindd_util.c
+++ b/source3/nsswitch/winbindd_util.c
@@ -27,6 +27,9 @@
#undef DBGC_CLASS
#define DBGC_CLASS DBGC_WINBIND
+extern struct winbindd_methods cache_methods;
+extern struct winbindd_methods passdb_methods;
+
/**
* @file winbindd_util.c
*
@@ -225,7 +228,6 @@ static void add_trusted_domains( struct winbindd_domain *domain )
static void trustdom_recv(void *private_data, BOOL success)
{
- extern struct winbindd_methods cache_methods;
struct trustdom_state *state =
talloc_get_type_abort(private_data, struct trustdom_state);
struct winbindd_response *response = state->response;
@@ -493,8 +495,6 @@ enum winbindd_result winbindd_dual_init_connection(struct winbindd_domain *domai
/* Look up global info for the winbind daemon */
BOOL init_domain_list(void)
{
- extern struct winbindd_methods cache_methods;
- extern struct winbindd_methods passdb_methods;
struct winbindd_domain *domain;
int role = lp_server_role();