diff options
author | Andrew Tridgell <tridge@samba.org> | 2008-08-08 11:41:21 +1000 |
---|---|---|
committer | Michael Adam <obnox@samba.org> | 2008-08-13 11:54:10 +0200 |
commit | 312a04528c2f3439f0451414fee224dfa4fcb6f4 (patch) | |
tree | dd08c36d7d651a24ac8715c4adc05e755f1e3eee | |
parent | 0f8a6859e63b5d842caf231e7003732051815963 (diff) | |
download | samba-312a04528c2f3439f0451414fee224dfa4fcb6f4.tar.gz samba-312a04528c2f3439f0451414fee224dfa4fcb6f4.tar.xz samba-312a04528c2f3439f0451414fee224dfa4fcb6f4.zip |
don't leave a dangling transaction on retry error
(This used to be commit ddf3022595fe8ca378c5f52107f42e296f852685)
-rw-r--r-- | source3/lib/dbwrap_util.c | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/source3/lib/dbwrap_util.c b/source3/lib/dbwrap_util.c index 09e9071d8c9..ddc613150bb 100644 --- a/source3/lib/dbwrap_util.c +++ b/source3/lib/dbwrap_util.c @@ -210,7 +210,8 @@ NTSTATUS dbwrap_trans_store(struct db_context *db, TDB_DATA key, TDB_DATA dbuf, if (res != 0) { DEBUG(5, ("tdb_transaction_commit failed\n")); status = NT_STATUS_INTERNAL_DB_CORRUPTION; - goto cancel; + TALLOC_FREE(rec); + return status; } return NT_STATUS_OK; @@ -255,7 +256,8 @@ NTSTATUS dbwrap_trans_delete(struct db_context *db, TDB_DATA key) if (res != 0) { DEBUG(5, ("tdb_transaction_commit failed\n")); status = NT_STATUS_INTERNAL_DB_CORRUPTION; - goto cancel; + TALLOC_FREE(rec); + return status; } return NT_STATUS_OK; |