diff options
author | Andrew Tridgell <tridge@samba.org> | 2009-09-03 18:33:17 +1000 |
---|---|---|
committer | Andrew Tridgell <tridge@samba.org> | 2009-09-03 18:36:10 +1000 |
commit | b72b8f6e7d6a83999153b71edd6f50a1803eff95 (patch) | |
tree | 267724f6cccc714cd5a26bb64d19307b9876b32a /source4/dsdb/samdb/ldb_modules/update_keytab.c | |
parent | 47f52e7a337f1f0e35c77f480146bbee3ac1d309 (diff) | |
download | samba-b72b8f6e7d6a83999153b71edd6f50a1803eff95.tar.gz samba-b72b8f6e7d6a83999153b71edd6f50a1803eff95.tar.bz2 samba-b72b8f6e7d6a83999153b71edd6f50a1803eff95.zip |
hook on prepare_commit instead of transaction_end
This allows for safe transaction end aborts
Diffstat (limited to 'source4/dsdb/samdb/ldb_modules/update_keytab.c')
-rw-r--r-- | source4/dsdb/samdb/ldb_modules/update_keytab.c | 8 |
1 files changed, 4 insertions, 4 deletions
diff --git a/source4/dsdb/samdb/ldb_modules/update_keytab.c b/source4/dsdb/samdb/ldb_modules/update_keytab.c index 302c1c8911..f08600ea32 100644 --- a/source4/dsdb/samdb/ldb_modules/update_keytab.c +++ b/source4/dsdb/samdb/ldb_modules/update_keytab.c @@ -378,8 +378,8 @@ static int update_kt_rename(struct ldb_module *module, struct ldb_request *req) return ldb_next_request(module, down_req); } -/* end a transaction */ -static int update_kt_end_trans(struct ldb_module *module) +/* prepare for a commit */ +static int update_kt_prepare_commit(struct ldb_module *module) { struct ldb_context *ldb; struct update_kt_private *data = talloc_get_type(ldb_module_get_private(module), struct update_kt_private); @@ -401,7 +401,7 @@ static int update_kt_end_trans(struct ldb_module *module) talloc_free(data->changed_dns); data->changed_dns = NULL; - return ldb_next_end_trans(module); + return ldb_next_prepare_commit(module); } /* end a transaction */ @@ -442,6 +442,6 @@ _PUBLIC_ const struct ldb_module_ops ldb_update_keytab_module_ops = { .modify = update_kt_modify, .rename = update_kt_rename, .del = update_kt_delete, - .end_transaction = update_kt_end_trans, + .prepare_commit = update_kt_prepare_commit, .del_transaction = update_kt_del_trans, }; |