diff options
author | Jeremy Allison <jra@samba.org> | 1998-02-20 19:48:01 +0000 |
---|---|---|
committer | Jeremy Allison <jra@samba.org> | 1998-02-20 19:48:01 +0000 |
commit | e58ab3bbe6e939ba678ad5482e58e0191c8dcbcb (patch) | |
tree | d2ad651521fc2f734697770c775fd5d155c89d18 /source/nmbd/nmbd_subnetdb.c | |
parent | 0a535680077a9e436362fd7f1711f62b35317fa4 (diff) | |
download | samba-e58ab3bbe6e939ba678ad5482e58e0191c8dcbcb.tar.gz |
nmbd_packets.c: nmbd_subnetdb.c: Patch from Andrey Alekseyev <fetch@muffin.arcadia.spb.ru>
to fix the fact that retransmit_or_expire_response_records() wasn't looking
at the WINS subnet.
server.c: Patch from jkf@soton.ac.uk to add %p (NIS server path) substitution.
smbpass.c: Fix to stop parsing failing on non-valid lines.
trans2.c: Fix for volume serial number code.
util.c: Patch from jkf@soton.ac.uk to add %p (NIS server path) substitution.
Fix for warnings under RH5. gcc 2.8.
Jeremy.
Diffstat (limited to 'source/nmbd/nmbd_subnetdb.c')
-rw-r--r-- | source/nmbd/nmbd_subnetdb.c | 24 |
1 files changed, 24 insertions, 0 deletions
diff --git a/source/nmbd/nmbd_subnetdb.c b/source/nmbd/nmbd_subnetdb.c index 5e18fe9cc0c..07692cc82c2 100644 --- a/source/nmbd/nmbd_subnetdb.c +++ b/source/nmbd/nmbd_subnetdb.c @@ -289,3 +289,27 @@ struct subnet_record *get_next_subnet_maybe_unicast(struct subnet_record *subrec else return subrec->next; } + +/******************************************************************* + Access function used by retransmit_or_expire_response_records() in + nmbd_packets.c. Patch from Andrey Alekseyev <fetch@muffin.arcadia.spb.ru> + Needed when we need to enumerate all the broadcast, unicast and + WINS subnets. +******************************************************************/ + +struct subnet_record *get_next_subnet_maybe_unicast_or_wins_server(struct subnet_record *subrec) +{ + if(subrec == unicast_subnet) + if(wins_server_subnet) + return wins_server_subnet; + else + return NULL; + + if(wins_server_subnet && subrec == wins_server_subnet) + return NULL; + + if((subrec->next == NULL) && we_are_a_wins_client()) + return unicast_subnet; + else + return subrec->next; +} |