summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
-rw-r--r--source3/include/proto.h2
-rw-r--r--source3/nameannounce.c5
-rw-r--r--source3/namedbsubnet.c3
-rw-r--r--source3/nameelect.c11
-rw-r--r--source3/nameserv.c1
-rw-r--r--source3/namework.c3
-rw-r--r--source3/nmbd/nmbd.c10
7 files changed, 6 insertions, 29 deletions
diff --git a/source3/include/proto.h b/source3/include/proto.h
index f257ac0048..f8685d21ea 100644
--- a/source3/include/proto.h
+++ b/source3/include/proto.h
@@ -488,8 +488,6 @@ void response_netbios_packet(struct packet_struct *p);
void reset_server(char *name, int state, struct in_addr ip);
void tell_become_backup(void);
BOOL same_context(struct dgram_packet *dgram);
-BOOL listening_name(struct work_record *work, struct nmb_name *n);
-BOOL listening_type(struct packet_struct *p, int command);
void process_browse_packet(struct packet_struct *p,char *buf,int len);
/*The following definitions come from nmbd.c */
diff --git a/source3/nameannounce.c b/source3/nameannounce.c
index 09aade86ef..5591c5ba19 100644
--- a/source3/nameannounce.c
+++ b/source3/nameannounce.c
@@ -42,9 +42,6 @@ extern int ClientNMB;
/* this is our domain/workgroup/server database */
extern struct subnet_record *subnetlist;
-/* machine comment for host announcements */
-extern pstring ServerComment;
-
extern int updatecount;
extern int workgroup_count;
@@ -307,7 +304,7 @@ void announce_host(void)
pstring comment;
char *my_name;
- StrnCpy(comment, *ServerComment ? ServerComment : "NoComment", 43);
+ StrnCpy(comment, lp_serverstring(), 43);
my_name = *myname ? myname : "NoName";
diff --git a/source3/namedbsubnet.c b/source3/namedbsubnet.c
index 5c683e5e49..0bad79246a 100644
--- a/source3/namedbsubnet.c
+++ b/source3/namedbsubnet.c
@@ -224,7 +224,6 @@ struct subnet_record *add_subnet_entry(struct in_addr bcast_ip,
(d = make_subnet(bcast_ip, mask_ip)))
{
struct work_record *w = find_workgroupstruct(d, name, add);
- extern pstring ServerComment;
if (!w) return NULL;
@@ -239,7 +238,7 @@ struct subnet_record *add_subnet_entry(struct in_addr bcast_ip,
lmhosts server entries to local interfaces */
if (strequal(lp_workgroup(), name))
{
- add_server_entry(d,w,myname,w->ServerType,0,ServerComment,True);
+ add_server_entry(d,w,myname,w->ServerType,0,lp_serverstring(),True);
DEBUG(3,("Added server name entry %s at %s\n",
name,inet_ntoa(bcast_ip)));
}
diff --git a/source3/nameelect.c b/source3/nameelect.c
index ef3935b1fd..041e4a8cca 100644
--- a/source3/nameelect.c
+++ b/source3/nameelect.c
@@ -43,9 +43,6 @@ extern pstring myname;
extern struct in_addr ipzero;
extern struct in_addr ipgrp;
-/* machine comment for host announcements */
-extern pstring ServerComment;
-
/* here are my election parameters */
extern time_t StartupTime;
@@ -266,7 +263,7 @@ void become_master(struct subnet_record *d, struct work_record *work)
/* update our server status */
work->ServerType &= ~SV_TYPE_POTENTIAL_BROWSER;
- add_server_entry(d,work,myname,work->ServerType,0,ServerComment,True);
+ add_server_entry(d,work,myname,work->ServerType,0,lp_serverstring(),True);
/* add special browser name */
add_my_name_entry(d,MSBROWSE ,0x01,nb_type|NB_ACTIVE|NB_GROUP);
@@ -295,7 +292,7 @@ void become_master(struct subnet_record *d, struct work_record *work)
/* update our server status */
work->ServerType |= SV_TYPE_MASTER_BROWSER;
- add_server_entry(d,work,myname,work->ServerType,0,ServerComment,True);
+ add_server_entry(d,work,myname,work->ServerType,0,lp_serverstring(),True);
if (work->serverlist == NULL) /* no servers! */
{
@@ -344,7 +341,7 @@ void become_master(struct subnet_record *d, struct work_record *work)
if (lp_domain_logons())
{
work->ServerType |= SV_TYPE_DOMAIN_MEMBER;
- add_server_entry(d,work,myname,work->ServerType,0,ServerComment,True);
+ add_server_entry(d,work,myname,work->ServerType,0,lp_serverstring(),True);
}
/* add domain master name */
@@ -380,7 +377,7 @@ void become_master(struct subnet_record *d, struct work_record *work)
}
work->ServerType |= update_type;
- add_server_entry(d,work,myname,work->ServerType,0,ServerComment,True);
+ add_server_entry(d,work,myname,work->ServerType,0,lp_serverstring(),True);
for (d1 = subnetlist; d1; d1 = d1->next)
{
diff --git a/source3/nameserv.c b/source3/nameserv.c
index 48b00d256d..d3aed24ab1 100644
--- a/source3/nameserv.c
+++ b/source3/nameserv.c
@@ -37,7 +37,6 @@ extern int DEBUGLEVEL;
extern pstring scope;
extern pstring myname;
-extern pstring ServerComment;
extern struct in_addr ipzero;
extern struct in_addr ipgrp;
diff --git a/source3/namework.c b/source3/namework.c
index 90ab2fb1fb..be034488c4 100644
--- a/source3/namework.c
+++ b/source3/namework.c
@@ -48,9 +48,6 @@ extern int workgroup_count; /* total number of workgroups we know about */
/* this is our domain/workgroup/server database */
extern struct subnet_record *subnetlist;
-/* machine comment for host announcements */
-extern pstring ServerComment;
-
extern int updatecount;
/* what server type are we currently */
diff --git a/source3/nmbd/nmbd.c b/source3/nmbd/nmbd.c
index 2621be87ee..097e4f794a 100644
--- a/source3/nmbd/nmbd.c
+++ b/source3/nmbd/nmbd.c
@@ -44,9 +44,6 @@ extern pstring myname;
/* are we running as a daemon ? */
static BOOL is_daemon = False;
-/* machine comment for host announcements */
-pstring ServerComment="";
-
/* what server type are we currently */
time_t StartupTime =0;
@@ -508,13 +505,6 @@ static void usage(char *pname)
DEBUG(3,("Loaded hosts file\n"));
}
-
-
- if (!*ServerComment)
- strcpy(ServerComment,"Samba %v");
- string_sub(ServerComment,"%v",VERSION);
- string_sub(ServerComment,"%h",myhostname);
-
add_my_names();
if (strequal(lp_workgroup(),"*")) {