diff options
author | Andrew Bartlett <abartlet@samba.org> | 2011-07-01 15:14:08 +1000 |
---|---|---|
committer | Andrew Bartlett <abartlet@samba.org> | 2011-07-02 12:31:34 +1000 |
commit | d4ef70a7645fb2fb21c565566c20619ff5d1a7ec (patch) | |
tree | 5c90ba64a51c142fe02735f88b6c36c316c0928d /source3 | |
parent | 6d8cc418ba9276c7aba0f5d07b420b2a79916d05 (diff) | |
download | samba-d4ef70a7645fb2fb21c565566c20619ff5d1a7ec.tar.gz samba-d4ef70a7645fb2fb21c565566c20619ff5d1a7ec.tar.bz2 samba-d4ef70a7645fb2fb21c565566c20619ff5d1a7ec.zip |
param: Finish conversion from lp_wins_support() -> lp_we_are_a_wins_server()
Jermey started this in 1997 with 0aa493cc0303aa4177f289b9e4c797c8fa180672
(avoiding the duplicate function makes it easier to generate the
struct loadparm_globals).
Andrew Bartlett
Diffstat (limited to 'source3')
-rw-r--r-- | source3/include/proto.h | 1 | ||||
-rw-r--r-- | source3/lib/wins_srv.c | 8 | ||||
-rw-r--r-- | source3/nmbd/nmbd_namelistdb.c | 2 | ||||
-rw-r--r-- | source3/param/loadparm.c | 1 | ||||
-rw-r--r-- | source3/rpc_server/svcctl/srv_svcctl_nt.c | 2 | ||||
-rw-r--r-- | source3/services/svc_wins.c | 2 | ||||
-rw-r--r-- | source3/utils/testparm.c | 2 | ||||
-rw-r--r-- | source3/web/swat.c | 4 |
8 files changed, 10 insertions, 12 deletions
diff --git a/source3/include/proto.h b/source3/include/proto.h index 73bd9baf5e..36ba416e78 100644 --- a/source3/include/proto.h +++ b/source3/include/proto.h @@ -1294,7 +1294,6 @@ bool lp_reset_on_zero_vc(void); bool lp_log_writeable_files_on_exit(void); bool lp_ms_add_printer_wizard(void); bool lp_dns_proxy(void); -bool lp_wins_support(void); bool lp_we_are_a_wins_server(void); bool lp_wins_proxy(void); bool lp_local_master(void); diff --git a/source3/lib/wins_srv.c b/source3/lib/wins_srv.c index f9e8f3b0e1..fb5587f9ba 100644 --- a/source3/lib/wins_srv.c +++ b/source3/lib/wins_srv.c @@ -153,7 +153,7 @@ unsigned wins_srv_count(void) const char **list; int count = 0; - if (lp_wins_support()) { + if (lp_we_are_a_wins_server()) { /* simple - just talk to ourselves */ return 1; } @@ -210,7 +210,7 @@ char **wins_srv_tags(void) int count=0, i, j; const char **list; - if (lp_wins_support()) { + if (lp_we_are_a_wins_server()) { /* give the caller something to chew on. This makes the rest of the logic simpler (ie. less special cases) */ ret = SMB_MALLOC_ARRAY(char *, 2); @@ -283,7 +283,7 @@ struct in_addr wins_srv_ip_tag(const char *tag, struct in_addr src_ip) struct tagged_ip t_ip; /* if we are a wins server then we always just talk to ourselves */ - if (lp_wins_support()) { + if (lp_we_are_a_wins_server()) { struct in_addr loopback_ip; loopback_ip.s_addr = htonl(INADDR_LOOPBACK); return loopback_ip; @@ -381,7 +381,7 @@ unsigned wins_srv_count_tag(const char *tag) int i, count=0; /* if we are a wins server then we always just talk to ourselves */ - if (lp_wins_support()) { + if (lp_we_are_a_wins_server()) { return 1; } diff --git a/source3/nmbd/nmbd_namelistdb.c b/source3/nmbd/nmbd_namelistdb.c index c6315f665d..61c1d784f7 100644 --- a/source3/nmbd/nmbd_namelistdb.c +++ b/source3/nmbd/nmbd_namelistdb.c @@ -33,7 +33,7 @@ uint16 samba_nb_type = 0; /* samba's NetBIOS name type */ void set_samba_nb_type(void) { - if( lp_wins_support() || wins_srv_count() ) { + if( lp_we_are_a_wins_server() || wins_srv_count() ) { samba_nb_type = NB_HFLAG; /* samba is a 'hybrid' node type. */ } else { samba_nb_type = NB_BFLAG; /* samba is broadcast-only node type. */ diff --git a/source3/param/loadparm.c b/source3/param/loadparm.c index 7b13a9f2c3..c7ed46fd8b 100644 --- a/source3/param/loadparm.c +++ b/source3/param/loadparm.c @@ -5652,7 +5652,6 @@ FN_GLOBAL_BOOL(lp_log_writeable_files_on_exit, bLogWriteableFilesOnExit) FN_GLOBAL_BOOL(lp_ms_add_printer_wizard, bMsAddPrinterWizard) FN_GLOBAL_BOOL(lp_dns_proxy, bDNSproxy) -FN_GLOBAL_BOOL(lp_wins_support, bWINSsupport) FN_GLOBAL_BOOL(lp_we_are_a_wins_server, bWINSsupport) FN_GLOBAL_BOOL(lp_wins_proxy, bWINSproxy) FN_GLOBAL_BOOL(lp_local_master, bLocalMaster) diff --git a/source3/rpc_server/svcctl/srv_svcctl_nt.c b/source3/rpc_server/svcctl/srv_svcctl_nt.c index f515906339..004aff4486 100644 --- a/source3/rpc_server/svcctl/srv_svcctl_nt.c +++ b/source3/rpc_server/svcctl/srv_svcctl_nt.c @@ -716,7 +716,7 @@ static WERROR fill_svc_config(TALLOC_CTX *mem_ctx, if ( strequal( name, "NETLOGON" ) && ( lp_servicenumber(name) == -1 ) ) config->start_type = SVCCTL_DISABLED; - else if ( strequal( name, "WINS" ) && ( !lp_wins_support() )) + else if ( strequal( name, "WINS" ) && ( !lp_we_are_a_wins_server() )) config->start_type = SVCCTL_DISABLED; else config->start_type = SVCCTL_DEMAND_START; diff --git a/source3/services/svc_wins.c b/source3/services/svc_wins.c index f1e94c5b7e..c8d72bc7c0 100644 --- a/source3/services/svc_wins.c +++ b/source3/services/svc_wins.c @@ -32,7 +32,7 @@ static WERROR wins_status( const char *service, struct SERVICE_STATUS *service_s service_status->type = SERVICE_TYPE_WIN32_OWN_PROCESS; service_status->controls_accepted = SVCCTL_ACCEPT_NONE; - if ( lp_wins_support() ) + if ( lp_we_are_a_wins_server() ) service_status->state = SVCCTL_RUNNING; else { service_status->state = SVCCTL_STOPPED; diff --git a/source3/utils/testparm.c b/source3/utils/testparm.c index 0634b25839..966b61e58e 100644 --- a/source3/utils/testparm.c +++ b/source3/utils/testparm.c @@ -72,7 +72,7 @@ static int do_global_checks(void) ret = 1; } - if (lp_wins_support() && lp_wins_server_list()) { + if (lp_we_are_a_wins_server() && lp_wins_server_list()) { fprintf(stderr, "ERROR: both 'wins support = true' and 'wins server = <server list>' \ cannot be set in the smb.conf file. nmbd will abort with this setting.\n"); ret = 1; diff --git a/source3/web/swat.c b/source3/web/swat.c index 3c209b5b3c..97c9613e25 100644 --- a/source3/web/swat.c +++ b/source3/web/swat.c @@ -775,7 +775,7 @@ static void wizard_page(void) else { /* Now determine smb.conf WINS settings */ - if (lp_wins_support()) + if (lp_we_are_a_wins_server()) winstype = 1; if (lp_wins_server_list() && strlen(*lp_wins_server_list())) winstype = 2; @@ -783,7 +783,7 @@ static void wizard_page(void) /* Do we have a homes share? */ have_home = lp_servicenumber(HOMES_NAME); } - if ((winstype == 2) && lp_wins_support()) + if ((winstype == 2) && lp_we_are_a_wins_server()) winstype = 3; role = lp_server_role(); |