diff options
author | Michael Adam <obnox@samba.org> | 2009-07-16 22:00:10 +0200 |
---|---|---|
committer | Ronnie Sahlberg <ronniesahlberg@gmail.com> | 2009-07-29 10:28:35 +1000 |
commit | 188ab0f96c1b78cb0ea4eb5c6d0407916ddf6719 (patch) | |
tree | 2878cc57c588f1d5f23cbb7fa2fc0532fdd43cea /ctdb/client | |
parent | 62c4a841d2cda9e96f70e00ed1c84908f69c3675 (diff) | |
download | samba-188ab0f96c1b78cb0ea4eb5c6d0407916ddf6719.tar.gz samba-188ab0f96c1b78cb0ea4eb5c6d0407916ddf6719.tar.xz samba-188ab0f96c1b78cb0ea4eb5c6d0407916ddf6719.zip |
client: set dmaster in ctdb_transaction_store() also when updating an existing record
Michael
(This used to be ctdb commit e9194a130327d6b05a8ab90bd976475b0e93b06d)
Diffstat (limited to 'ctdb/client')
-rw-r--r-- | ctdb/client/ctdb_client.c | 4 |
1 files changed, 2 insertions, 2 deletions
diff --git a/ctdb/client/ctdb_client.c b/ctdb/client/ctdb_client.c index 38893568848..19a935023f4 100644 --- a/ctdb/client/ctdb_client.c +++ b/ctdb/client/ctdb_client.c @@ -3268,8 +3268,7 @@ int ctdb_transaction_store(struct ctdb_transaction_handle *h, /* the record doesn't exist - create one with us as dmaster. This is only safe because we are in a transaction and this is a persistent database */ - header.dmaster = h->ctdb_db->ctdb->pnn; - header.rsn = 0; + ZERO_STRUCT(header); } else if (ret != 0) { DEBUG(DEBUG_ERR,(__location__ " Failed to fetch record\n")); talloc_free(tmp_ctx); @@ -3283,6 +3282,7 @@ int ctdb_transaction_store(struct ctdb_transaction_handle *h, return 0; } + header.dmaster = h->ctdb_db->ctdb->pnn; header.rsn++; if (!h->in_replay) { |