Skip to content

Commit

Permalink
Undo changes to renew
Browse files Browse the repository at this point in the history
  • Loading branch information
kriszyp committed Mar 10, 2024
1 parent 7c8c903 commit cbc10c3
Show file tree
Hide file tree
Showing 2 changed files with 6 additions and 5 deletions.
6 changes: 3 additions & 3 deletions dependencies/lmdb/libraries/liblmdb/mdb.c
Original file line number Diff line number Diff line change
Expand Up @@ -3483,13 +3483,13 @@ mdb_txn_renew(MDB_txn *txn)
if (!txn)
last_error = "No transaction to renew";
else if (F_ISSET(txn->mt_flags, MDB_TXN_RDONLY)) {
// Txn is already renewed, consider this as invalid for compatibility with v1
return EINVAL;
// Txn is already renewed, we can just keep using it
return MDB_SUCCESS;
} else {
last_error = malloc(100);
sprintf(last_error, "Transaction flag was invalid for renew: %u", txn->mt_flags);
}
return MDB_BAD_TXN; // if the transaction is not read-only, communicate this with a separate error code
return EINVAL;
}

rc = mdb_txn_renew0(txn);
Expand Down
5 changes: 3 additions & 2 deletions package.json
Original file line number Diff line number Diff line change
@@ -1,7 +1,7 @@
{
"name": "lmdb",
"author": "Kris Zyp",
"version": "2.9.3",
"version": "2.9.4",
"description": "Simple, efficient, scalable, high-performance LMDB interface",
"license": "MIT",
"repository": {
Expand Down Expand Up @@ -109,5 +109,6 @@
"useTabs": true,
"singleQuote": true
},
"optionalDependencies": {}
"optionalDependencies": {
}
}

0 comments on commit cbc10c3

Please sign in to comment.