diff options
author | Andrew Tridgell <tridge@samba.org> | 2007-06-07 18:13:14 +1000 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2007-06-07 18:13:14 +1000 |
commit | c42ddcda235a9b3673ea7882f48010b4e01068d7 (patch) | |
tree | b6902685e137f484c873840f77a52f7cb6ad896c /ctdb | |
parent | 96861466b7a0538e50eeab2922c02d6c5ba22ca1 (diff) | |
download | samba-c42ddcda235a9b3673ea7882f48010b4e01068d7.tar.gz samba-c42ddcda235a9b3673ea7882f48010b4e01068d7.tar.xz samba-c42ddcda235a9b3673ea7882f48010b4e01068d7.zip |
validate vnn on node flags change
(This used to be ctdb commit 5628ebbcc2aa61b63c761783c70fe4d8a0070607)
Diffstat (limited to 'ctdb')
-rw-r--r-- | ctdb/common/ctdb_daemon.c | 6 |
1 files changed, 6 insertions, 0 deletions
diff --git a/ctdb/common/ctdb_daemon.c b/ctdb/common/ctdb_daemon.c index 761e8fb33e..cecd64fab8 100644 --- a/ctdb/common/ctdb_daemon.c +++ b/ctdb/common/ctdb_daemon.c @@ -44,10 +44,16 @@ static void flag_change_handler(struct ctdb_context *ctdb, uint64_t srvid, return; } + if (!ctdb_validate_vnn(ctdb, c->vnn)) { + DEBUG(0,("Bad vnn %u in flag_change_handler\n", c->vnn)); + return; + } + /* don't get the disconnected flag from the other node */ ctdb->nodes[c->vnn]->flags = (ctdb->nodes[c->vnn]->flags&NODE_FLAGS_DISCONNECTED) | (c->flags & ~NODE_FLAGS_DISCONNECTED); + DEBUG(2,("Node flags for node %u are now 0x%x\n", c->vnn, ctdb->nodes[c->vnn]->flags)); } /* called when the "startup" event script has finished */ |