Skip to content

Commit

Permalink
Expose C handle for MDBX environment
Browse files Browse the repository at this point in the history
  • Loading branch information
canepat committed Oct 6, 2023
1 parent 63fe990 commit ea6ad78
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions mdbx/env.go
Original file line number Diff line number Diff line change
Expand Up @@ -618,3 +618,7 @@ func (env *Env) run(lock bool, flags uint, fn TxnOp) error {
func (env *Env) CloseDBI(db DBI) {
C.mdbx_dbi_close(env._env, C.MDBX_dbi(db))
}

func (env *Env) CHandle() unsafe.Pointer {
return unsafe.Pointer(env._env)
}

0 comments on commit ea6ad78

Please sign in to comment.