summaryrefslogtreecommitdiffstats
path: root/lib/tdb/test/run-nested-transactions.c
diff options
context:
space:
mode:
Diffstat (limited to 'lib/tdb/test/run-nested-transactions.c')
-rw-r--r--lib/tdb/test/run-nested-transactions.c7
1 files changed, 4 insertions, 3 deletions
diff --git a/lib/tdb/test/run-nested-transactions.c b/lib/tdb/test/run-nested-transactions.c
index 7c83846c2e9..c4765def341 100644
--- a/lib/tdb/test/run-nested-transactions.c
+++ b/lib/tdb/test/run-nested-transactions.c
@@ -26,11 +26,11 @@ int main(int argc, char *argv[])
key.dptr = (void *)"hi";
tdb = tdb_open_ex("run-nested-transactions.tdb",
- 1024, TDB_CLEAR_IF_FIRST,
+ 1024, TDB_CLEAR_IF_FIRST|TDB_DISALLOW_NESTING,
O_CREAT|O_TRUNC|O_RDWR, 0600, &taplogctx, NULL);
ok1(tdb);
- /* No nesting by default. */
+ /* Nesting disallowed. */
ok1(tdb_transaction_start(tdb) == 0);
data.dptr = (void *)"world";
data.dsize = strlen("world");
@@ -53,8 +53,9 @@ int main(int argc, char *argv[])
free(data.dptr);
tdb_close(tdb);
+ /* Nesting allowed by default */
tdb = tdb_open_ex("run-nested-transactions.tdb",
- 1024, TDB_ALLOW_NESTING, O_RDWR, 0, &taplogctx, NULL);
+ 1024, TDB_DEFAULT, O_RDWR, 0, &taplogctx, NULL);
ok1(tdb);
ok1(tdb_transaction_start(tdb) == 0);