From 9fdb312a69bc966aed8d917843559cb235e17a10 Mon Sep 17 00:00:00 2001 From: Samba Release Account Date: Tue, 9 Jul 1996 18:01:46 +0000 Subject: sorted out various timer delay bugs: nameannounce.c nameserv.c namedbname.c:search_for_name() wasn't looking for 0x1b as well as 0x0 and 0x20 name types. reduced number of retransmissions of packets from 4 to 3 times. added code that ensures remote lmhosts entries don't get deleted when a master browser cannot be found on a remote subnet. stopped forcing an election on remote subnets if a master browser cannot be found. stopped browse list and wins list from being written out too frequently. only add samba's names to local interfaces. add 0x1c name if we are a domain logon machine (needs more exploration). why bother reloading services when receiving a SIGTERM? sort out add_my_name_entry() and remove_name_entry() to deal with broadcast, samba as a WINS and samba using a WINS. properly. added extra debug information to help with expected response queue code. updated debug comments in become_master(). altered dump_names() DEBUG format. it looks prettier. altered wins.dat format to match DEBUG format. lkcl (This used to be commit 429f1f975e2936f2e220b656c51c211d48d47047) --- source3/namedbresp.c | 11 ++++++++--- 1 file changed, 8 insertions(+), 3 deletions(-) (limited to 'source3/namedbresp.c') diff --git a/source3/namedbresp.c b/source3/namedbresp.c index a9abc5d9b5..c453d9bbec 100644 --- a/source3/namedbresp.c +++ b/source3/namedbresp.c @@ -50,6 +50,9 @@ void add_response_record(struct subnet_record *d, num_response_packets++; /* count of total number of packets still around */ + DEBUG(4,("adding response record id:%d num_records:%d\n", + n->response_id, num_response_packets)); + if (!d->responselist) { d->responselist = n; @@ -89,7 +92,7 @@ void remove_response_record(struct subnet_record *d, create a name query response record **************************************************************************/ struct response_record *make_response_queue_record(enum state_type state, - int id,int fd, + int id,uint16 fd, int quest_type, char *name,int type, int nb_flags, time_t ttl, BOOL bcast,BOOL recurse, struct in_addr send_ip, struct in_addr reply_to_ip) @@ -114,8 +117,8 @@ struct response_record *make_response_queue_record(enum state_type state, n->reply_to_ip = reply_to_ip; n->repeat_interval = 1; /* XXXX should be in ms */ - n->repeat_count = 4; - n->repeat_time = time(NULL) + n->repeat_interval; + n->repeat_count = 3; /* 3 retries */ + n->repeat_time = time(NULL) + n->repeat_interval; /* initial retry time */ n->num_msgs = 0; @@ -138,6 +141,8 @@ struct response_record *find_response_record(struct subnet_record **d, for (n = (*d)->responselist; n; n = n->next) { if (n->response_id == id) { + DEBUG(4, ("found response record on %s: %d\n", + inet_ntoa((*d)->bcast_ip), id)); return n; } } -- cgit