summaryrefslogtreecommitdiff
path: root/source/nmbd/nmbd_subnetdb.c
diff options
context:
space:
mode:
authorChristopher R. Hertel <crh@samba.org>2000-07-19 01:21:30 +0000
committerChristopher R. Hertel <crh@samba.org>2000-07-19 01:21:30 +0000
commitcc08bdc74f4cd111fdc582ee7babef47ed8a950d (patch)
tree7e67fd511973cd47d8ac581803890415c4873e5c /source/nmbd/nmbd_subnetdb.c
parent1b718f67675e52520f193a8c71c110246e70723f (diff)
downloadsamba-cc08bdc74f4cd111fdc582ee7babef47ed8a950d.tar.gz
First cut toward adding WINS server failover.
*Note: failover doesn't actually work yet!* It's just that the code I'm adding provides all of the pieces necessary. I do have one big question. Something that I'll have to ask Jeremy, I'm thinkin'. In nmbd/nmbd_subnetdb.c the IP of the WINS server is used to set up the Unicast subnet. ...so what happens if the WINS server changes? My guess is either: a) nothing. b) I'd have to change the unicast subnet entry whenever the WINS server changes. Urq. BTW, the lp_wins_server() function no longer returns the WINS server name or IP. It returns the list of WINS servers entered in smb.conf. To get the currently 'live' WINS server, use the wins_srv() function. Fun, eh? Chris -)-----
Diffstat (limited to 'source/nmbd/nmbd_subnetdb.c')
-rw-r--r--source/nmbd/nmbd_subnetdb.c6
1 files changed, 5 insertions, 1 deletions
diff --git a/source/nmbd/nmbd_subnetdb.c b/source/nmbd/nmbd_subnetdb.c
index 330be4057f1..57f937148e8 100644
--- a/source/nmbd/nmbd_subnetdb.c
+++ b/source/nmbd/nmbd_subnetdb.c
@@ -271,12 +271,16 @@ BOOL create_subnets(void)
* get the ip address of it here. If we are the WINS server then
* set the unicast subnet address to be the first of our own real
* addresses.
+ *
+ * NOTE: I'm not sure of the implications of WINS server failover
+ * on this bit of code. Because of failover, the WINS
+ * server address can change.
*/
if(*lp_wins_server())
{
struct in_addr real_wins_ip;
- real_wins_ip = *interpret_addr2(lp_wins_server());
+ real_wins_ip = *interpret_addr2( wins_srv() );
if (!zero_ip(real_wins_ip))
{