mariadb/storage/bdb/sequence/sequence.c
unknown 47d10d0eca Import BDB 4.3.28
storage/bdb/LICENSE:
  Import db-4.3.28
storage/bdb/btree/bt_compare.c:
  Import db-4.3.28
storage/bdb/btree/bt_conv.c:
  Import db-4.3.28
storage/bdb/btree/bt_curadj.c:
  Import db-4.3.28
storage/bdb/btree/bt_cursor.c:
  Import db-4.3.28
storage/bdb/btree/bt_delete.c:
  Import db-4.3.28
storage/bdb/btree/bt_method.c:
  Import db-4.3.28
storage/bdb/btree/bt_open.c:
  Import db-4.3.28
storage/bdb/btree/bt_put.c:
  Import db-4.3.28
storage/bdb/btree/bt_rec.c:
  Import db-4.3.28
storage/bdb/btree/bt_reclaim.c:
  Import db-4.3.28
storage/bdb/btree/bt_recno.c:
  Import db-4.3.28
storage/bdb/btree/bt_rsearch.c:
  Import db-4.3.28
storage/bdb/btree/bt_search.c:
  Import db-4.3.28
storage/bdb/btree/bt_split.c:
  Import db-4.3.28
storage/bdb/btree/bt_stat.c:
  Import db-4.3.28
storage/bdb/btree/bt_upgrade.c:
  Import db-4.3.28
storage/bdb/btree/bt_verify.c:
  Import db-4.3.28
storage/bdb/btree/btree.src:
  Import db-4.3.28
storage/bdb/build_win32/Berkeley_DB.dsw:
  Import db-4.3.28
storage/bdb/build_win32/app_dsp.src:
  Import db-4.3.28
storage/bdb/build_win32/db_test.src:
  Import db-4.3.28
storage/bdb/build_win32/dbkill.cpp:
  Import db-4.3.28
storage/bdb/build_win32/dynamic_dsp.src:
  Import db-4.3.28
storage/bdb/build_win32/java_dsp.src:
  Import db-4.3.28
storage/bdb/build_win32/libdb_tcl.def:
  Import db-4.3.28
storage/bdb/build_win32/libdbrc.src:
  Import db-4.3.28
storage/bdb/build_win32/static_dsp.src:
  Import db-4.3.28
storage/bdb/build_win32/tcl_dsp.src:
  Import db-4.3.28
storage/bdb/clib/getcwd.c:
  Import db-4.3.28
storage/bdb/clib/getopt.c:
  Import db-4.3.28
storage/bdb/clib/memcmp.c:
  Import db-4.3.28
storage/bdb/clib/memmove.c:
  Import db-4.3.28
storage/bdb/clib/raise.c:
  Import db-4.3.28
storage/bdb/clib/snprintf.c:
  Import db-4.3.28
storage/bdb/clib/strcasecmp.c:
  Import db-4.3.28
storage/bdb/clib/strdup.c:
  Import db-4.3.28
storage/bdb/clib/strerror.c:
  Import db-4.3.28
storage/bdb/common/db_byteorder.c:
  Import db-4.3.28
storage/bdb/common/db_err.c:
  Import db-4.3.28
storage/bdb/common/db_getlong.c:
  Import db-4.3.28
storage/bdb/common/db_idspace.c:
  Import db-4.3.28
storage/bdb/common/db_log2.c:
  Import db-4.3.28
storage/bdb/common/util_arg.c:
  Import db-4.3.28
storage/bdb/common/util_cache.c:
  Import db-4.3.28
storage/bdb/common/util_log.c:
  Import db-4.3.28
storage/bdb/common/util_sig.c:
  Import db-4.3.28
storage/bdb/cxx/cxx_db.cpp:
  Import db-4.3.28
storage/bdb/cxx/cxx_dbc.cpp:
  Import db-4.3.28
storage/bdb/cxx/cxx_dbt.cpp:
  Import db-4.3.28
storage/bdb/cxx/cxx_env.cpp:
  Import db-4.3.28
storage/bdb/cxx/cxx_except.cpp:
  Import db-4.3.28
storage/bdb/cxx/cxx_lock.cpp:
  Import db-4.3.28
storage/bdb/cxx/cxx_logc.cpp:
  Import db-4.3.28
storage/bdb/cxx/cxx_mpool.cpp:
  Import db-4.3.28
storage/bdb/cxx/cxx_txn.cpp:
  Import db-4.3.28
storage/bdb/db/crdel.src:
  Import db-4.3.28
storage/bdb/db/crdel_rec.c:
  Import db-4.3.28
storage/bdb/db/db.c:
  Import db-4.3.28
storage/bdb/db/db.src:
  Import db-4.3.28
storage/bdb/db/db_am.c:
  Import db-4.3.28
storage/bdb/db/db_cam.c:
  Import db-4.3.28
storage/bdb/db/db_conv.c:
  Import db-4.3.28
storage/bdb/db/db_dispatch.c:
  Import db-4.3.28
storage/bdb/db/db_dup.c:
  Import db-4.3.28
storage/bdb/db/db_iface.c:
  Import db-4.3.28
storage/bdb/db/db_join.c:
  Import db-4.3.28
storage/bdb/db/db_meta.c:
  Import db-4.3.28
storage/bdb/db/db_method.c:
  Import db-4.3.28
storage/bdb/db/db_open.c:
  Import db-4.3.28
storage/bdb/db/db_overflow.c:
  Import db-4.3.28
storage/bdb/db/db_pr.c:
  Import db-4.3.28
storage/bdb/db/db_rec.c:
  Import db-4.3.28
storage/bdb/db/db_reclaim.c:
  Import db-4.3.28
storage/bdb/db/db_remove.c:
  Import db-4.3.28
storage/bdb/db/db_rename.c:
  Import db-4.3.28
storage/bdb/db/db_ret.c:
  Import db-4.3.28
storage/bdb/db/db_truncate.c:
  Import db-4.3.28
storage/bdb/db/db_upg.c:
  Import db-4.3.28
storage/bdb/db/db_upg_opd.c:
  Import db-4.3.28
storage/bdb/db/db_vrfy.c:
  Import db-4.3.28
storage/bdb/db/db_vrfyutil.c:
  Import db-4.3.28
storage/bdb/db185/db185.c:
  Import db-4.3.28
storage/bdb/db185/db185_int.in:
  Import db-4.3.28
storage/bdb/db_archive/db_archive.c:
  Import db-4.3.28
storage/bdb/db_checkpoint/db_checkpoint.c:
  Import db-4.3.28
storage/bdb/db_deadlock/db_deadlock.c:
  Import db-4.3.28
storage/bdb/db_dump/db_dump.c:
  Import db-4.3.28
storage/bdb/db_dump185/db_dump185.c:
  Import db-4.3.28
storage/bdb/db_load/db_load.c:
  Import db-4.3.28
storage/bdb/db_printlog/README:
  Import db-4.3.28
storage/bdb/db_printlog/db_printlog.c:
  Import db-4.3.28
storage/bdb/db_printlog/dbname.awk:
  Import db-4.3.28
storage/bdb/db_printlog/rectype.awk:
  Import db-4.3.28
storage/bdb/db_printlog/status.awk:
  Import db-4.3.28
storage/bdb/db_recover/db_recover.c:
  Import db-4.3.28
storage/bdb/db_stat/db_stat.c:
  Import db-4.3.28
storage/bdb/db_upgrade/db_upgrade.c:
  Import db-4.3.28
storage/bdb/db_verify/db_verify.c:
  Import db-4.3.28
storage/bdb/dbinc/btree.h:
  Import db-4.3.28
storage/bdb/dbinc/crypto.h:
  Import db-4.3.28
storage/bdb/dbinc/cxx_int.h:
  Import db-4.3.28
storage/bdb/dbinc/db.in:
  Import db-4.3.28
storage/bdb/dbinc/db_185.in:
  Import db-4.3.28
storage/bdb/dbinc/db_am.h:
  Import db-4.3.28
storage/bdb/dbinc/db_cxx.in:
  Import db-4.3.28
storage/bdb/dbinc/db_dispatch.h:
  Import db-4.3.28
storage/bdb/dbinc/db_int.in:
  Import db-4.3.28
storage/bdb/dbinc/db_join.h:
  Import db-4.3.28
storage/bdb/dbinc/db_page.h:
  Import db-4.3.28
storage/bdb/dbinc/db_server_int.h:
  Import db-4.3.28
storage/bdb/dbinc/db_shash.h:
  Import db-4.3.28
storage/bdb/dbinc/db_swap.h:
  Import db-4.3.28
storage/bdb/dbinc/db_upgrade.h:
  Import db-4.3.28
storage/bdb/dbinc/db_verify.h:
  Import db-4.3.28
storage/bdb/dbinc/debug.h:
  Import db-4.3.28
storage/bdb/dbinc/fop.h:
  Import db-4.3.28
storage/bdb/dbinc/globals.h:
  Import db-4.3.28
storage/bdb/dbinc/hash.h:
  Import db-4.3.28
storage/bdb/dbinc/hmac.h:
  Import db-4.3.28
storage/bdb/dbinc/lock.h:
  Import db-4.3.28
storage/bdb/dbinc/log.h:
  Import db-4.3.28
storage/bdb/dbinc/mp.h:
  Import db-4.3.28
storage/bdb/dbinc/mutex.h:
  Import db-4.3.28
storage/bdb/dbinc/os.h:
  Import db-4.3.28
storage/bdb/dbinc/qam.h:
  Import db-4.3.28
storage/bdb/dbinc/queue.h:
  Import db-4.3.28
storage/bdb/dbinc/region.h:
  Import db-4.3.28
storage/bdb/dbinc/rep.h:
  Import db-4.3.28
storage/bdb/dbinc/shqueue.h:
  Import db-4.3.28
storage/bdb/dbinc/tcl_db.h:
  Import db-4.3.28
storage/bdb/dbinc/txn.h:
  Import db-4.3.28
storage/bdb/dbinc/xa.h:
  Import db-4.3.28
storage/bdb/dbm/dbm.c:
  Import db-4.3.28
storage/bdb/dbreg/dbreg.c:
  Import db-4.3.28
storage/bdb/dbreg/dbreg.src:
  Import db-4.3.28
storage/bdb/dbreg/dbreg_rec.c:
  Import db-4.3.28
storage/bdb/dbreg/dbreg_util.c:
  Import db-4.3.28
storage/bdb/dist/Makefile.in:
  Import db-4.3.28
storage/bdb/dist/RELEASE:
  Import db-4.3.28
storage/bdb/dist/aclocal/config.ac:
  Import db-4.3.28
storage/bdb/dist/aclocal/libtool.ac:
  Import db-4.3.28
storage/bdb/dist/aclocal/mutex.ac:
  Import db-4.3.28
storage/bdb/dist/aclocal/options.ac:
  Import db-4.3.28
storage/bdb/dist/aclocal/programs.ac:
  Import db-4.3.28
storage/bdb/dist/aclocal/sosuffix.ac:
  Import db-4.3.28
storage/bdb/dist/aclocal/tcl.ac:
  Import db-4.3.28
storage/bdb/dist/aclocal/types.ac:
  Import db-4.3.28
storage/bdb/dist/aclocal_java/ac_jni_include_dirs.ac:
  Import db-4.3.28
storage/bdb/dist/aclocal_java/ac_prog_java.ac:
  Import db-4.3.28
storage/bdb/dist/buildrel:
  Import db-4.3.28
storage/bdb/dist/configure.ac:
  Import db-4.3.28
storage/bdb/dist/gen_inc.awk:
  Import db-4.3.28
storage/bdb/dist/gen_rec.awk:
  Import db-4.3.28
storage/bdb/dist/gen_rpc.awk:
  Import db-4.3.28
storage/bdb/dist/ltmain.sh:
  Import db-4.3.28
storage/bdb/dist/pubdef.in:
  Import db-4.3.28
storage/bdb/dist/srcfiles.in:
  Import db-4.3.28
storage/bdb/dist/vx_2.0/BerkeleyDB.wpj:
  Import db-4.3.28
storage/bdb/dist/vx_2.0/wpj.in:
  Import db-4.3.28
storage/bdb/dist/vx_config.in:
  Import db-4.3.28
storage/bdb/dist/vx_setup/CONFIG.in:
  Import db-4.3.28
storage/bdb/dist/vx_setup/LICENSE.TXT:
  Import db-4.3.28
storage/bdb/dist/vx_setup/vx_allfile.in:
  Import db-4.3.28
storage/bdb/dist/vx_setup/vx_demofile.in:
  Import db-4.3.28
storage/bdb/dist/win_config.in:
  Import db-4.3.28
storage/bdb/dist/win_exports.in:
  Import db-4.3.28
storage/bdb/env/db_salloc.c:
  Import db-4.3.28
storage/bdb/env/db_shash.c:
  Import db-4.3.28
storage/bdb/env/env_file.c:
  Import db-4.3.28
storage/bdb/env/env_method.c:
  Import db-4.3.28
storage/bdb/env/env_open.c:
  Import db-4.3.28
storage/bdb/env/env_recover.c:
  Import db-4.3.28
storage/bdb/env/env_region.c:
  Import db-4.3.28
storage/bdb/fileops/fileops.src:
  Import db-4.3.28
storage/bdb/fileops/fop_basic.c:
  Import db-4.3.28
storage/bdb/fileops/fop_rec.c:
  Import db-4.3.28
storage/bdb/fileops/fop_util.c:
  Import db-4.3.28
storage/bdb/hash/hash.c:
  Import db-4.3.28
storage/bdb/hash/hash.src:
  Import db-4.3.28
storage/bdb/hash/hash_conv.c:
  Import db-4.3.28
storage/bdb/hash/hash_dup.c:
  Import db-4.3.28
storage/bdb/hash/hash_func.c:
  Import db-4.3.28
storage/bdb/hash/hash_meta.c:
  Import db-4.3.28
storage/bdb/hash/hash_method.c:
  Import db-4.3.28
storage/bdb/hash/hash_open.c:
  Import db-4.3.28
storage/bdb/hash/hash_page.c:
  Import db-4.3.28
storage/bdb/hash/hash_rec.c:
  Import db-4.3.28
storage/bdb/hash/hash_reclaim.c:
  Import db-4.3.28
storage/bdb/hash/hash_stat.c:
  Import db-4.3.28
storage/bdb/hash/hash_upgrade.c:
  Import db-4.3.28
storage/bdb/hash/hash_verify.c:
  Import db-4.3.28
storage/bdb/hmac/hmac.c:
  Import db-4.3.28
storage/bdb/hmac/sha1.c:
  Import db-4.3.28
storage/bdb/hsearch/hsearch.c:
  Import db-4.3.28
storage/bdb/lock/lock.c:
  Import db-4.3.28
storage/bdb/lock/lock_deadlock.c:
  Import db-4.3.28
storage/bdb/lock/lock_method.c:
  Import db-4.3.28
storage/bdb/lock/lock_region.c:
  Import db-4.3.28
storage/bdb/lock/lock_stat.c:
  Import db-4.3.28
storage/bdb/lock/lock_util.c:
  Import db-4.3.28
storage/bdb/log/log.c:
  Import db-4.3.28
storage/bdb/log/log_archive.c:
  Import db-4.3.28
storage/bdb/log/log_compare.c:
  Import db-4.3.28
storage/bdb/log/log_get.c:
  Import db-4.3.28
storage/bdb/log/log_method.c:
  Import db-4.3.28
storage/bdb/log/log_put.c:
  Import db-4.3.28
storage/bdb/mp/mp_alloc.c:
  Import db-4.3.28
storage/bdb/mp/mp_bh.c:
  Import db-4.3.28
storage/bdb/mp/mp_fget.c:
  Import db-4.3.28
storage/bdb/mp/mp_fopen.c:
  Import db-4.3.28
storage/bdb/mp/mp_fput.c:
  Import db-4.3.28
storage/bdb/mp/mp_fset.c:
  Import db-4.3.28
storage/bdb/mp/mp_method.c:
  Import db-4.3.28
storage/bdb/mp/mp_region.c:
  Import db-4.3.28
storage/bdb/mp/mp_register.c:
  Import db-4.3.28
storage/bdb/mp/mp_stat.c:
  Import db-4.3.28
storage/bdb/mp/mp_sync.c:
  Import db-4.3.28
storage/bdb/mp/mp_trickle.c:
  Import db-4.3.28
storage/bdb/mutex/mut_fcntl.c:
  Import db-4.3.28
storage/bdb/mutex/mut_pthread.c:
  Import db-4.3.28
storage/bdb/mutex/mut_tas.c:
  Import db-4.3.28
storage/bdb/mutex/mut_win32.c:
  Import db-4.3.28
storage/bdb/mutex/mutex.c:
  Import db-4.3.28
storage/bdb/mutex/tm.c:
  Import db-4.3.28
storage/bdb/mutex/uts4_cc.s:
  Import db-4.3.28
storage/bdb/os/os_abs.c:
  Import db-4.3.28
storage/bdb/os/os_alloc.c:
  Import db-4.3.28
storage/bdb/os/os_clock.c:
  Import db-4.3.28
storage/bdb/os/os_config.c:
  Import db-4.3.28
storage/bdb/os/os_dir.c:
  Import db-4.3.28
storage/bdb/os/os_errno.c:
  Import db-4.3.28
storage/bdb/os/os_fid.c:
  Import db-4.3.28
storage/bdb/os/os_fsync.c:
  Import db-4.3.28
storage/bdb/os/os_handle.c:
  Import db-4.3.28
storage/bdb/os/os_id.c:
  Import db-4.3.28
storage/bdb/os/os_map.c:
  Import db-4.3.28
storage/bdb/os/os_method.c:
  Import db-4.3.28
storage/bdb/os/os_oflags.c:
  Import db-4.3.28
storage/bdb/os/os_open.c:
  Import db-4.3.28
storage/bdb/os/os_region.c:
  Import db-4.3.28
storage/bdb/os/os_rename.c:
  Import db-4.3.28
storage/bdb/os/os_root.c:
  Import db-4.3.28
storage/bdb/os/os_rpath.c:
  Import db-4.3.28
storage/bdb/os/os_rw.c:
  Import db-4.3.28
storage/bdb/os/os_seek.c:
  Import db-4.3.28
storage/bdb/os/os_sleep.c:
  Import db-4.3.28
storage/bdb/os/os_spin.c:
  Import db-4.3.28
storage/bdb/os/os_stat.c:
  Import db-4.3.28
storage/bdb/os/os_tmpdir.c:
  Import db-4.3.28
storage/bdb/os/os_unlink.c:
  Import db-4.3.28
storage/bdb/os_vxworks/os_vx_abs.c:
  Import db-4.3.28
storage/bdb/os_vxworks/os_vx_config.c:
  Import db-4.3.28
storage/bdb/os_vxworks/os_vx_map.c:
  Import db-4.3.28
storage/bdb/os_win32/os_abs.c:
  Import db-4.3.28
storage/bdb/os_win32/os_clock.c:
  Import db-4.3.28
storage/bdb/os_win32/os_config.c:
  Import db-4.3.28
storage/bdb/os_win32/os_dir.c:
  Import db-4.3.28
storage/bdb/os_win32/os_errno.c:
  Import db-4.3.28
storage/bdb/os_win32/os_fid.c:
  Import db-4.3.28
storage/bdb/os_win32/os_fsync.c:
  Import db-4.3.28
storage/bdb/os_win32/os_handle.c:
  Import db-4.3.28
storage/bdb/os_win32/os_map.c:
  Import db-4.3.28
storage/bdb/os_win32/os_open.c:
  Import db-4.3.28
storage/bdb/os_win32/os_rename.c:
  Import db-4.3.28
storage/bdb/os_win32/os_rw.c:
  Import db-4.3.28
storage/bdb/os_win32/os_seek.c:
  Import db-4.3.28
storage/bdb/os_win32/os_sleep.c:
  Import db-4.3.28
storage/bdb/os_win32/os_spin.c:
  Import db-4.3.28
storage/bdb/os_win32/os_stat.c:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/BerkeleyDB.pm:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/BerkeleyDB.pod.P:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/BerkeleyDB.pod:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/BerkeleyDB.xs:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/Changes:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/MANIFEST:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/Makefile.PL:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/README:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/config.in:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/constants.h:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/mkconsts:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/patches/5.004:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/ppport.h:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/scan:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/btree.t:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/destroy.t:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/env.t:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/filter.t:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/hash.t:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/join.t:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/mldbm.t:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/queue.t:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/recno.t:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/strict.t:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/subdb.t:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/txn.t:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/util.pm:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/typemap:
  Import db-4.3.28
storage/bdb/perl/DB_File/Changes:
  Import db-4.3.28
storage/bdb/perl/DB_File/DB_File.pm:
  Import db-4.3.28
storage/bdb/perl/DB_File/DB_File.xs:
  Import db-4.3.28
storage/bdb/perl/DB_File/MANIFEST:
  Import db-4.3.28
storage/bdb/perl/DB_File/Makefile.PL:
  Import db-4.3.28
storage/bdb/perl/DB_File/README:
  Import db-4.3.28
storage/bdb/perl/DB_File/dbinfo:
  Import db-4.3.28
storage/bdb/perl/DB_File/patches/5.004:
  Import db-4.3.28
storage/bdb/perl/DB_File/ppport.h:
  Import db-4.3.28
storage/bdb/perl/DB_File/t/db-btree.t:
  Import db-4.3.28
storage/bdb/perl/DB_File/t/db-hash.t:
  Import db-4.3.28
storage/bdb/perl/DB_File/t/db-recno.t:
  Import db-4.3.28
storage/bdb/perl/DB_File/typemap:
  Import db-4.3.28
storage/bdb/qam/qam.c:
  Import db-4.3.28
storage/bdb/qam/qam.src:
  Import db-4.3.28
storage/bdb/qam/qam_conv.c:
  Import db-4.3.28
storage/bdb/qam/qam_files.c:
  Import db-4.3.28
storage/bdb/qam/qam_method.c:
  Import db-4.3.28
storage/bdb/qam/qam_open.c:
  Import db-4.3.28
storage/bdb/qam/qam_rec.c:
  Import db-4.3.28
storage/bdb/qam/qam_stat.c:
  Import db-4.3.28
storage/bdb/qam/qam_upgrade.c:
  Import db-4.3.28
storage/bdb/qam/qam_verify.c:
  Import db-4.3.28
storage/bdb/rep/rep_method.c:
  Import db-4.3.28
storage/bdb/rep/rep_record.c:
  Import db-4.3.28
storage/bdb/rep/rep_region.c:
  Import db-4.3.28
storage/bdb/rep/rep_util.c:
  Import db-4.3.28
storage/bdb/rpc_client/client.c:
  Import db-4.3.28
storage/bdb/rpc_client/gen_client_ret.c:
  Import db-4.3.28
storage/bdb/rpc_server/c/db_server_util.c:
  Import db-4.3.28
storage/bdb/rpc_server/cxx/db_server_cxxproc.cpp:
  Import db-4.3.28
storage/bdb/rpc_server/cxx/db_server_cxxutil.cpp:
  Import db-4.3.28
storage/bdb/rpc_server/java/FreeList.java:
  Import db-4.3.28
storage/bdb/rpc_server/java/LocalIterator.java:
  Import db-4.3.28
storage/bdb/rpc_server/java/README:
  Import db-4.3.28
storage/bdb/rpc_server/java/RpcDb.java:
  Import db-4.3.28
storage/bdb/rpc_server/java/RpcDbEnv.java:
  Import db-4.3.28
storage/bdb/rpc_server/java/RpcDbTxn.java:
  Import db-4.3.28
storage/bdb/rpc_server/java/RpcDbc.java:
  Import db-4.3.28
storage/bdb/rpc_server/java/Timer.java:
  Import db-4.3.28
storage/bdb/rpc_server/java/gen/__db_open_reply.java:
  Import db-4.3.28
storage/bdb/rpc_server/java/gen/__db_stat_msg.java:
  Import db-4.3.28
storage/bdb/rpc_server/java/gen/db_server.java:
  Import db-4.3.28
storage/bdb/rpc_server/java/s_jrpcgen:
  Import db-4.3.28
storage/bdb/rpc_server/rpc.src:
  Import db-4.3.28
storage/bdb/tcl/docs/db.html:
  Import db-4.3.28
storage/bdb/tcl/docs/env.html:
  Import db-4.3.28
storage/bdb/tcl/docs/historic.html:
  Import db-4.3.28
storage/bdb/tcl/docs/index.html:
  Import db-4.3.28
storage/bdb/tcl/docs/library.html:
  Import db-4.3.28
storage/bdb/tcl/docs/lock.html:
  Import db-4.3.28
storage/bdb/tcl/docs/log.html:
  Import db-4.3.28
storage/bdb/tcl/docs/mpool.html:
  Import db-4.3.28
storage/bdb/tcl/docs/rep.html:
  Import db-4.3.28
storage/bdb/tcl/docs/test.html:
  Import db-4.3.28
storage/bdb/tcl/docs/txn.html:
  Import db-4.3.28
storage/bdb/tcl/tcl_compat.c:
  Import db-4.3.28
storage/bdb/tcl/tcl_db.c:
  Import db-4.3.28
storage/bdb/tcl/tcl_db_pkg.c:
  Import db-4.3.28
storage/bdb/tcl/tcl_dbcursor.c:
  Import db-4.3.28
storage/bdb/tcl/tcl_env.c:
  Import db-4.3.28
storage/bdb/tcl/tcl_internal.c:
  Import db-4.3.28
storage/bdb/tcl/tcl_lock.c:
  Import db-4.3.28
storage/bdb/tcl/tcl_log.c:
  Import db-4.3.28
storage/bdb/tcl/tcl_mp.c:
  Import db-4.3.28
storage/bdb/tcl/tcl_rep.c:
  Import db-4.3.28
storage/bdb/tcl/tcl_txn.c:
  Import db-4.3.28
storage/bdb/tcl/tcl_util.c:
  Import db-4.3.28
storage/bdb/test/archive.tcl:
  Import db-4.3.28
storage/bdb/test/bigfile001.tcl:
  Import db-4.3.28
storage/bdb/test/bigfile002.tcl:
  Import db-4.3.28
storage/bdb/test/byteorder.tcl:
  Import db-4.3.28
storage/bdb/test/conscript.tcl:
  Import db-4.3.28
storage/bdb/test/dbm.tcl:
  Import db-4.3.28
storage/bdb/test/dbscript.tcl:
  Import db-4.3.28
storage/bdb/test/ddoyscript.tcl:
  Import db-4.3.28
storage/bdb/test/ddscript.tcl:
  Import db-4.3.28
storage/bdb/test/dead001.tcl:
  Import db-4.3.28
storage/bdb/test/dead002.tcl:
  Import db-4.3.28
storage/bdb/test/dead003.tcl:
  Import db-4.3.28
storage/bdb/test/dead004.tcl:
  Import db-4.3.28
storage/bdb/test/dead005.tcl:
  Import db-4.3.28
storage/bdb/test/dead006.tcl:
  Import db-4.3.28
storage/bdb/test/dead007.tcl:
  Import db-4.3.28
storage/bdb/test/env001.tcl:
  Import db-4.3.28
storage/bdb/test/env002.tcl:
  Import db-4.3.28
storage/bdb/test/env003.tcl:
  Import db-4.3.28
storage/bdb/test/env004.tcl:
  Import db-4.3.28
storage/bdb/test/env005.tcl:
  Import db-4.3.28
storage/bdb/test/env006.tcl:
  Import db-4.3.28
storage/bdb/test/env007.tcl:
  Import db-4.3.28
storage/bdb/test/env008.tcl:
  Import db-4.3.28
storage/bdb/test/env009.tcl:
  Import db-4.3.28
storage/bdb/test/env010.tcl:
  Import db-4.3.28
storage/bdb/test/env011.tcl:
  Import db-4.3.28
storage/bdb/test/hsearch.tcl:
  Import db-4.3.28
storage/bdb/test/join.tcl:
  Import db-4.3.28
storage/bdb/test/lock001.tcl:
  Import db-4.3.28
storage/bdb/test/lock002.tcl:
  Import db-4.3.28
storage/bdb/test/lock003.tcl:
  Import db-4.3.28
storage/bdb/test/lock004.tcl:
  Import db-4.3.28
storage/bdb/test/lock005.tcl:
  Import db-4.3.28
storage/bdb/test/lockscript.tcl:
  Import db-4.3.28
storage/bdb/test/log001.tcl:
  Import db-4.3.28
storage/bdb/test/log002.tcl:
  Import db-4.3.28
storage/bdb/test/log003.tcl:
  Import db-4.3.28
storage/bdb/test/log004.tcl:
  Import db-4.3.28
storage/bdb/test/log005.tcl:
  Import db-4.3.28
storage/bdb/test/logtrack.tcl:
  Import db-4.3.28
storage/bdb/test/mdbscript.tcl:
  Import db-4.3.28
storage/bdb/test/memp001.tcl:
  Import db-4.3.28
storage/bdb/test/memp002.tcl:
  Import db-4.3.28
storage/bdb/test/memp003.tcl:
  Import db-4.3.28
storage/bdb/test/mpoolscript.tcl:
  Import db-4.3.28
storage/bdb/test/mutex001.tcl:
  Import db-4.3.28
storage/bdb/test/mutex002.tcl:
  Import db-4.3.28
storage/bdb/test/mutex003.tcl:
  Import db-4.3.28
storage/bdb/test/mutexscript.tcl:
  Import db-4.3.28
storage/bdb/test/ndbm.tcl:
  Import db-4.3.28
storage/bdb/test/parallel.tcl:
  Import db-4.3.28
storage/bdb/test/recd001.tcl:
  Import db-4.3.28
storage/bdb/test/recd002.tcl:
  Import db-4.3.28
storage/bdb/test/recd003.tcl:
  Import db-4.3.28
storage/bdb/test/recd004.tcl:
  Import db-4.3.28
storage/bdb/test/recd005.tcl:
  Import db-4.3.28
storage/bdb/test/recd006.tcl:
  Import db-4.3.28
storage/bdb/test/recd007.tcl:
  Import db-4.3.28
storage/bdb/test/recd008.tcl:
  Import db-4.3.28
storage/bdb/test/recd009.tcl:
  Import db-4.3.28
storage/bdb/test/recd010.tcl:
  Import db-4.3.28
storage/bdb/test/recd011.tcl:
  Import db-4.3.28
storage/bdb/test/recd012.tcl:
  Import db-4.3.28
storage/bdb/test/recd013.tcl:
  Import db-4.3.28
storage/bdb/test/recd014.tcl:
  Import db-4.3.28
storage/bdb/test/recd015.tcl:
  Import db-4.3.28
storage/bdb/test/recd016.tcl:
  Import db-4.3.28
storage/bdb/test/recd017.tcl:
  Import db-4.3.28
storage/bdb/test/recd018.tcl:
  Import db-4.3.28
storage/bdb/test/recd019.tcl:
  Import db-4.3.28
storage/bdb/test/recd020.tcl:
  Import db-4.3.28
storage/bdb/test/recd15scr.tcl:
  Import db-4.3.28
storage/bdb/test/recdscript.tcl:
  Import db-4.3.28
storage/bdb/test/rep001.tcl:
  Import db-4.3.28
storage/bdb/test/rep002.tcl:
  Import db-4.3.28
storage/bdb/test/rep003.tcl:
  Import db-4.3.28
storage/bdb/test/rep005.tcl:
  Import db-4.3.28
storage/bdb/test/reputils.tcl:
  Import db-4.3.28
storage/bdb/test/rpc001.tcl:
  Import db-4.3.28
storage/bdb/test/rpc002.tcl:
  Import db-4.3.28
storage/bdb/test/rpc003.tcl:
  Import db-4.3.28
storage/bdb/test/rpc004.tcl:
  Import db-4.3.28
storage/bdb/test/rpc005.tcl:
  Import db-4.3.28
storage/bdb/test/rsrc001.tcl:
  Import db-4.3.28
storage/bdb/test/rsrc002.tcl:
  Import db-4.3.28
storage/bdb/test/rsrc003.tcl:
  Import db-4.3.28
storage/bdb/test/rsrc004.tcl:
  Import db-4.3.28
storage/bdb/test/scr001/chk.code:
  Import db-4.3.28
storage/bdb/test/scr003/chk.define:
  Import db-4.3.28
storage/bdb/test/scr004/chk.javafiles:
  Import db-4.3.28
storage/bdb/test/scr005/chk.nl:
  Import db-4.3.28
storage/bdb/test/scr006/chk.offt:
  Import db-4.3.28
storage/bdb/test/scr007/chk.proto:
  Import db-4.3.28
storage/bdb/test/scr008/chk.pubdef:
  Import db-4.3.28
storage/bdb/test/scr009/chk.srcfiles:
  Import db-4.3.28
storage/bdb/test/scr010/chk.str:
  Import db-4.3.28
storage/bdb/test/scr010/spell.ok:
  Import db-4.3.28
storage/bdb/test/scr011/chk.tags:
  Import db-4.3.28
storage/bdb/test/scr012/chk.vx_code:
  Import db-4.3.28
storage/bdb/test/scr013/chk.stats:
  Import db-4.3.28
storage/bdb/test/scr015/TestConstruct01.cpp:
  Import db-4.3.28
storage/bdb/test/scr015/TestConstruct01.testerr:
  Import db-4.3.28
storage/bdb/test/scr015/TestGetSetMethods.cpp:
  Import db-4.3.28
storage/bdb/test/scr015/TestKeyRange.cpp:
  Import db-4.3.28
storage/bdb/test/scr015/TestLogc.cpp:
  Import db-4.3.28
storage/bdb/test/scr015/TestSimpleAccess.cpp:
  Import db-4.3.28
storage/bdb/test/scr015/TestTruncate.cpp:
  Import db-4.3.28
storage/bdb/test/scr015/chk.cxxtests:
  Import db-4.3.28
storage/bdb/test/scr016/CallbackTest.java:
  Import db-4.3.28
storage/bdb/test/scr016/CallbackTest.testout:
  Import db-4.3.28
storage/bdb/test/scr016/TestAppendRecno.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestAssociate.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestClosedDb.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestClosedDb.testout:
  Import db-4.3.28
storage/bdb/test/scr016/TestConstruct01.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestConstruct01.testout:
  Import db-4.3.28
storage/bdb/test/scr016/TestConstruct02.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestDbtFlags.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestGetSetMethods.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestKeyRange.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestLockVec.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestLogc.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestOpenEmpty.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestOpenEmpty.testerr:
  Import db-4.3.28
storage/bdb/test/scr016/TestReplication.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestRpcServer.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestSameDbt.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestSimpleAccess.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestStat.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestStat.testout:
  Import db-4.3.28
storage/bdb/test/scr016/TestTruncate.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestTruncate.testout:
  Import db-4.3.28
storage/bdb/test/scr016/TestUtil.java:
  Import db-4.3.28
storage/bdb/test/scr016/TestXAServlet.java:
  Import db-4.3.28
storage/bdb/test/scr016/chk.javatests:
  Import db-4.3.28
storage/bdb/test/scr016/ignore:
  Import db-4.3.28
storage/bdb/test/scr016/testone:
  Import db-4.3.28
storage/bdb/test/scr017/chk.db185:
  Import db-4.3.28
storage/bdb/test/scr019/chk.include:
  Import db-4.3.28
storage/bdb/test/scr020/chk.inc:
  Import db-4.3.28
storage/bdb/test/scr021/chk.flags:
  Import db-4.3.28
storage/bdb/test/scr022/chk.rr:
  Import db-4.3.28
storage/bdb/test/sdb001.tcl:
  Import db-4.3.28
storage/bdb/test/sdb002.tcl:
  Import db-4.3.28
storage/bdb/test/sdb003.tcl:
  Import db-4.3.28
storage/bdb/test/sdb004.tcl:
  Import db-4.3.28
storage/bdb/test/sdb005.tcl:
  Import db-4.3.28
storage/bdb/test/sdb006.tcl:
  Import db-4.3.28
storage/bdb/test/sdb007.tcl:
  Import db-4.3.28
storage/bdb/test/sdb008.tcl:
  Import db-4.3.28
storage/bdb/test/sdb009.tcl:
  Import db-4.3.28
storage/bdb/test/sdb010.tcl:
  Import db-4.3.28
storage/bdb/test/sdb011.tcl:
  Import db-4.3.28
storage/bdb/test/sdb012.tcl:
  Import db-4.3.28
storage/bdb/test/sdbscript.tcl:
  Import db-4.3.28
storage/bdb/test/sdbtest001.tcl:
  Import db-4.3.28
storage/bdb/test/sdbtest002.tcl:
  Import db-4.3.28
storage/bdb/test/sdbutils.tcl:
  Import db-4.3.28
storage/bdb/test/sec001.tcl:
  Import db-4.3.28
storage/bdb/test/sec002.tcl:
  Import db-4.3.28
storage/bdb/test/shelltest.tcl:
  Import db-4.3.28
storage/bdb/test/si001.tcl:
  Import db-4.3.28
storage/bdb/test/si002.tcl:
  Import db-4.3.28
storage/bdb/test/si003.tcl:
  Import db-4.3.28
storage/bdb/test/si004.tcl:
  Import db-4.3.28
storage/bdb/test/si005.tcl:
  Import db-4.3.28
storage/bdb/test/sysscript.tcl:
  Import db-4.3.28
storage/bdb/test/test.tcl:
  Import db-4.3.28
storage/bdb/test/test001.tcl:
  Import db-4.3.28
storage/bdb/test/test002.tcl:
  Import db-4.3.28
storage/bdb/test/test003.tcl:
  Import db-4.3.28
storage/bdb/test/test004.tcl:
  Import db-4.3.28
storage/bdb/test/test005.tcl:
  Import db-4.3.28
storage/bdb/test/test006.tcl:
  Import db-4.3.28
storage/bdb/test/test007.tcl:
  Import db-4.3.28
storage/bdb/test/test008.tcl:
  Import db-4.3.28
storage/bdb/test/test009.tcl:
  Import db-4.3.28
storage/bdb/test/test010.tcl:
  Import db-4.3.28
storage/bdb/test/test011.tcl:
  Import db-4.3.28
storage/bdb/test/test012.tcl:
  Import db-4.3.28
storage/bdb/test/test013.tcl:
  Import db-4.3.28
storage/bdb/test/test014.tcl:
  Import db-4.3.28
storage/bdb/test/test015.tcl:
  Import db-4.3.28
storage/bdb/test/test016.tcl:
  Import db-4.3.28
storage/bdb/test/test017.tcl:
  Import db-4.3.28
storage/bdb/test/test018.tcl:
  Import db-4.3.28
storage/bdb/test/test019.tcl:
  Import db-4.3.28
storage/bdb/test/test020.tcl:
  Import db-4.3.28
storage/bdb/test/test021.tcl:
  Import db-4.3.28
storage/bdb/test/test022.tcl:
  Import db-4.3.28
storage/bdb/test/test023.tcl:
  Import db-4.3.28
storage/bdb/test/test024.tcl:
  Import db-4.3.28
storage/bdb/test/test025.tcl:
  Import db-4.3.28
storage/bdb/test/test026.tcl:
  Import db-4.3.28
storage/bdb/test/test027.tcl:
  Import db-4.3.28
storage/bdb/test/test028.tcl:
  Import db-4.3.28
storage/bdb/test/test029.tcl:
  Import db-4.3.28
storage/bdb/test/test030.tcl:
  Import db-4.3.28
storage/bdb/test/test031.tcl:
  Import db-4.3.28
storage/bdb/test/test032.tcl:
  Import db-4.3.28
storage/bdb/test/test033.tcl:
  Import db-4.3.28
storage/bdb/test/test034.tcl:
  Import db-4.3.28
storage/bdb/test/test035.tcl:
  Import db-4.3.28
storage/bdb/test/test036.tcl:
  Import db-4.3.28
storage/bdb/test/test037.tcl:
  Import db-4.3.28
storage/bdb/test/test038.tcl:
  Import db-4.3.28
storage/bdb/test/test039.tcl:
  Import db-4.3.28
storage/bdb/test/test040.tcl:
  Import db-4.3.28
storage/bdb/test/test041.tcl:
  Import db-4.3.28
storage/bdb/test/test042.tcl:
  Import db-4.3.28
storage/bdb/test/test043.tcl:
  Import db-4.3.28
storage/bdb/test/test044.tcl:
  Import db-4.3.28
storage/bdb/test/test045.tcl:
  Import db-4.3.28
storage/bdb/test/test046.tcl:
  Import db-4.3.28
storage/bdb/test/test047.tcl:
  Import db-4.3.28
storage/bdb/test/test048.tcl:
  Import db-4.3.28
storage/bdb/test/test049.tcl:
  Import db-4.3.28
storage/bdb/test/test050.tcl:
  Import db-4.3.28
storage/bdb/test/test051.tcl:
  Import db-4.3.28
storage/bdb/test/test052.tcl:
  Import db-4.3.28
storage/bdb/test/test053.tcl:
  Import db-4.3.28
storage/bdb/test/test054.tcl:
  Import db-4.3.28
storage/bdb/test/test055.tcl:
  Import db-4.3.28
storage/bdb/test/test056.tcl:
  Import db-4.3.28
storage/bdb/test/test057.tcl:
  Import db-4.3.28
storage/bdb/test/test058.tcl:
  Import db-4.3.28
storage/bdb/test/test059.tcl:
  Import db-4.3.28
storage/bdb/test/test060.tcl:
  Import db-4.3.28
storage/bdb/test/test061.tcl:
  Import db-4.3.28
storage/bdb/test/test062.tcl:
  Import db-4.3.28
storage/bdb/test/test063.tcl:
  Import db-4.3.28
storage/bdb/test/test064.tcl:
  Import db-4.3.28
storage/bdb/test/test065.tcl:
  Import db-4.3.28
storage/bdb/test/test066.tcl:
  Import db-4.3.28
storage/bdb/test/test067.tcl:
  Import db-4.3.28
storage/bdb/test/test068.tcl:
  Import db-4.3.28
storage/bdb/test/test069.tcl:
  Import db-4.3.28
storage/bdb/test/test070.tcl:
  Import db-4.3.28
storage/bdb/test/test071.tcl:
  Import db-4.3.28
storage/bdb/test/test072.tcl:
  Import db-4.3.28
storage/bdb/test/test073.tcl:
  Import db-4.3.28
storage/bdb/test/test074.tcl:
  Import db-4.3.28
storage/bdb/test/test076.tcl:
  Import db-4.3.28
storage/bdb/test/test077.tcl:
  Import db-4.3.28
storage/bdb/test/test078.tcl:
  Import db-4.3.28
storage/bdb/test/test079.tcl:
  Import db-4.3.28
storage/bdb/test/test081.tcl:
  Import db-4.3.28
storage/bdb/test/test082.tcl:
  Import db-4.3.28
storage/bdb/test/test083.tcl:
  Import db-4.3.28
storage/bdb/test/test084.tcl:
  Import db-4.3.28
storage/bdb/test/test085.tcl:
  Import db-4.3.28
storage/bdb/test/test086.tcl:
  Import db-4.3.28
storage/bdb/test/test087.tcl:
  Import db-4.3.28
storage/bdb/test/test088.tcl:
  Import db-4.3.28
storage/bdb/test/test089.tcl:
  Import db-4.3.28
storage/bdb/test/test090.tcl:
  Import db-4.3.28
storage/bdb/test/test091.tcl:
  Import db-4.3.28
storage/bdb/test/test092.tcl:
  Import db-4.3.28
storage/bdb/test/test093.tcl:
  Import db-4.3.28
storage/bdb/test/test094.tcl:
  Import db-4.3.28
storage/bdb/test/test095.tcl:
  Import db-4.3.28
storage/bdb/test/test096.tcl:
  Import db-4.3.28
storage/bdb/test/test097.tcl:
  Import db-4.3.28
storage/bdb/test/test098.tcl:
  Import db-4.3.28
storage/bdb/test/test099.tcl:
  Import db-4.3.28
storage/bdb/test/test100.tcl:
  Import db-4.3.28
storage/bdb/test/test101.tcl:
  Import db-4.3.28
storage/bdb/test/testparams.tcl:
  Import db-4.3.28
storage/bdb/test/testutils.tcl:
  Import db-4.3.28
storage/bdb/test/txn001.tcl:
  Import db-4.3.28
storage/bdb/test/txn002.tcl:
  Import db-4.3.28
storage/bdb/test/txn003.tcl:
  Import db-4.3.28
storage/bdb/test/txn004.tcl:
  Import db-4.3.28
storage/bdb/test/txn005.tcl:
  Import db-4.3.28
storage/bdb/test/txn006.tcl:
  Import db-4.3.28
storage/bdb/test/txn007.tcl:
  Import db-4.3.28
storage/bdb/test/txn008.tcl:
  Import db-4.3.28
storage/bdb/test/txn009.tcl:
  Import db-4.3.28
storage/bdb/test/txnscript.tcl:
  Import db-4.3.28
storage/bdb/test/update.tcl:
  Import db-4.3.28
storage/bdb/test/upgrade.tcl:
  Import db-4.3.28
storage/bdb/test/wrap.tcl:
  Import db-4.3.28
storage/bdb/txn/txn.c:
  Import db-4.3.28
storage/bdb/txn/txn.src:
  Import db-4.3.28
storage/bdb/txn/txn_method.c:
  Import db-4.3.28
storage/bdb/txn/txn_rec.c:
  Import db-4.3.28
storage/bdb/txn/txn_recover.c:
  Import db-4.3.28
storage/bdb/txn/txn_region.c:
  Import db-4.3.28
storage/bdb/txn/txn_stat.c:
  Import db-4.3.28
storage/bdb/txn/txn_util.c:
  Import db-4.3.28
storage/bdb/xa/xa.c:
  Import db-4.3.28
storage/bdb/xa/xa_db.c:
  Import db-4.3.28
storage/bdb/xa/xa_map.c:
  Import db-4.3.28
storage/bdb/clib/strtol.c:
  Import db-4.3.28
storage/bdb/clib/strtoul.c:
  Import db-4.3.28
storage/bdb/common/crypto_stub.c:
  Import db-4.3.28
storage/bdb/crypto/aes_method.c:
  Import db-4.3.28
storage/bdb/crypto/crypto.c:
  Import db-4.3.28
storage/bdb/crypto/crypto.html:
  Import db-4.3.28
storage/bdb/crypto/mersenne/mt19937db.c:
  Import db-4.3.28
storage/bdb/crypto/rijndael/rijndael-alg-fst.c:
  Import db-4.3.28
storage/bdb/crypto/rijndael/rijndael-alg-fst.h:
  Import db-4.3.28
storage/bdb/crypto/rijndael/rijndael-api-fst.c:
  Import db-4.3.28
storage/bdb/crypto/rijndael/rijndael-api-fst.h:
  Import db-4.3.28
storage/bdb/cxx/cxx_multi.cpp:
  Import db-4.3.28
storage/bdb/cxx/cxx_seq.cpp:
  Import db-4.3.28
storage/bdb/db/db_ovfl_vrfy.c:
  Import db-4.3.28
storage/bdb/db/db_setid.c:
  Import db-4.3.28
storage/bdb/db/db_setlsn.c:
  Import db-4.3.28
storage/bdb/db/db_stati.c:
  Import db-4.3.28
storage/bdb/db/db_vrfy_stub.c:
  Import db-4.3.28
storage/bdb/db_stat/dd.sh:
  Import db-4.3.28
storage/bdb/dbreg/dbreg_stat.c:
  Import db-4.3.28
storage/bdb/dist/aclocal/rpc.ac:
  Import db-4.3.28
storage/bdb/dist/aclocal/sequence.ac:
  Import db-4.3.28
storage/bdb/dist/config.hin:
  Import db-4.3.28
storage/bdb/dist/s_java_const:
  Import db-4.3.28
storage/bdb/dist/s_java_stat:
  Import db-4.3.28
storage/bdb/dist/s_java_swig:
  Import db-4.3.28
storage/bdb/dist/s_je2db:
  Import db-4.3.28
storage/bdb/dist/s_winmsi:
  Import db-4.3.28
storage/bdb/dist/template/db_server_proc:
  Import db-4.3.28
storage/bdb/dist/template/gen_client_ret:
  Import db-4.3.28
storage/bdb/dist/template/rec_btree:
  Import db-4.3.28
storage/bdb/dist/template/rec_crdel:
  Import db-4.3.28
storage/bdb/dist/template/rec_dbreg:
  Import db-4.3.28
storage/bdb/dist/template/rec_db:
  Import db-4.3.28
storage/bdb/dist/template/rec_fileops:
  Import db-4.3.28
storage/bdb/dist/template/rec_hash:
  Import db-4.3.28
storage/bdb/dist/template/rec_qam:
  Import db-4.3.28
storage/bdb/dist/template/rec_rep:
  Import db-4.3.28
storage/bdb/dist/template/rec_txn:
  Import db-4.3.28
storage/bdb/dist/vx_2.0/BerkeleyDBsmall.wpj:
  Import db-4.3.28
storage/bdb/dist/vx_2.2/BerkeleyDB.wpj:
  Import db-4.3.28
storage/bdb/dist/vx_2.2/BerkeleyDBsmall.wpj:
  Import db-4.3.28
storage/bdb/dist/vx_2.2/wpj.in:
  Import db-4.3.28
storage/bdb/dist/win_db.in:
  Import db-4.3.28
storage/bdb/dist/winmsi/dbcorewix.in:
  Import db-4.3.28
storage/bdb/dist/winmsi/dbvarsbat.in:
  Import db-4.3.28
storage/bdb/dist/winmsi/dbwix.m4:
  Import db-4.3.28
storage/bdb/dist/winmsi/environment.in:
  Import db-4.3.28
storage/bdb/dist/winmsi/features.in:
  Import db-4.3.28
storage/bdb/dist/winmsi/files.in:
  Import db-4.3.28
storage/bdb/dist/winmsi/images/caticon.ibd:
  Import db-4.3.28
storage/bdb/dist/winmsi/images/foldernew.ibd:
  Import db-4.3.28
storage/bdb/dist/winmsi/images/folderup.ibd:
  Import db-4.3.28
storage/bdb/dist/winmsi/images/sleepycat.jpg:
  Import db-4.3.28
storage/bdb/dist/winmsi/images/topstripe.ibd:
  Import db-4.3.28
storage/bdb/dist/winmsi/images/webicon.ico:
  Import db-4.3.28
storage/bdb/dist/winmsi/links.in:
  Import db-4.3.28
storage/bdb/dist/winmsi/s_winmsi.fcn:
  Import db-4.3.28
storage/bdb/dist/winmsi/winbuild.bat:
  Import db-4.3.28
storage/bdb/env/env_stat.c:
  Import db-4.3.28
storage/bdb/hash/hash_stub.c:
  Import db-4.3.28
storage/bdb/lock/lock_id.c:
  Import db-4.3.28
storage/bdb/lock/lock_list.c:
  Import db-4.3.28
storage/bdb/lock/lock_timer.c:
  Import db-4.3.28
storage/bdb/log/log_stat.c:
  Import db-4.3.28
storage/bdb/mp/mp_fmethod.c:
  Import db-4.3.28
storage/bdb/os/os_truncate.c:
  Import db-4.3.28
storage/bdb/os_win32/os_truncate.c:
  Import db-4.3.28
storage/bdb/os_win32/os_unlink.c:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/META.yml:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/cds.t:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/encrypt.t:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/t/pod.t:
  Import db-4.3.28
storage/bdb/perl/DB_File/META.yml:
  Import db-4.3.28
storage/bdb/qam/qam_stub.c:
  Import db-4.3.28
storage/bdb/rep/rep.src:
  Import db-4.3.28
storage/bdb/rep/rep_backup.c:
  Import db-4.3.28
storage/bdb/rep/rep_stat.c:
  Import db-4.3.28
storage/bdb/rep/rep_stub.c:
  Import db-4.3.28
storage/bdb/rpc_client/gen_client.c:
  Import db-4.3.28
storage/bdb/rpc_server/c/db_server_proc.c:
  Import db-4.3.28
storage/bdb/rpc_server/c/gen_db_server.c:
  Import db-4.3.28
storage/bdb/rpc_server/db_server.x:
  Import db-4.3.28
storage/bdb/sequence/seq_stat.c:
  Import db-4.3.28
storage/bdb/sequence/sequence.c:
  Import db-4.3.28
storage/bdb/tcl/tcl_seq.c:
  Import db-4.3.28
storage/bdb/dist/config.guess:
  Import db-4.3.28
storage/bdb/dist/config.sub:
  Import db-4.3.28
storage/bdb/dist/s_all:
  Import db-4.3.28
storage/bdb/dist/s_config:
  Import db-4.3.28
storage/bdb/dist/s_crypto:
  Import db-4.3.28
storage/bdb/dist/s_include:
  Import db-4.3.28
storage/bdb/dist/s_java:
  Import db-4.3.28
storage/bdb/dist/s_perm:
  Import db-4.3.28
storage/bdb/dist/s_readme:
  Import db-4.3.28
storage/bdb/dist/s_recover:
  Import db-4.3.28
storage/bdb/dist/s_rpc:
  Import db-4.3.28
storage/bdb/dist/s_symlink:
  Import db-4.3.28
storage/bdb/dist/s_tags:
  Import db-4.3.28
storage/bdb/dist/s_test:
  Import db-4.3.28
storage/bdb/dist/s_vxworks:
  Import db-4.3.28
storage/bdb/dist/s_win32_dsp:
  Import db-4.3.28
storage/bdb/dist/s_win32:
  Import db-4.3.28
storage/bdb/perl/BerkeleyDB/dbinfo:
  Import db-4.3.28
2005-07-20 15:48:22 -07:00

747 lines
17 KiB
C

/*-
* See the file LICENSE for redistribution information.
*
* Copyright (c) 2004
* Sleepycat Software. All rights reserved.
*
* $Id: sequence.c,v 1.26 2004/10/25 17:59:28 bostic Exp $
*/
#include "db_config.h"
#ifndef NO_SYSTEM_INCLUDES
#include <sys/types.h>
#include <stdlib.h>
#include <string.h>
#endif
#include "db_int.h"
#include "dbinc/db_shash.h"
#include "dbinc/db_page.h"
#include "dbinc/db_swap.h"
#include "dbinc/db_am.h"
#include "dbinc/mp.h"
#include "dbinc_auto/sequence_ext.h"
#ifdef HAVE_SEQUENCE
#define SEQ_ILLEGAL_AFTER_OPEN(seq, name) \
if (seq->seq_key.data != NULL) \
return (__db_mi_open((seq)->seq_dbp->dbenv, name, 1));
#define SEQ_ILLEGAL_BEFORE_OPEN(seq, name) \
if (seq->seq_key.data == NULL) \
return (__db_mi_open((seq)->seq_dbp->dbenv, name, 0));
#define SEQ_SWAP(rp) \
do { \
M_32_SWAP((rp)->seq_version); \
M_32_SWAP((rp)->flags); \
M_64_SWAP((rp)->seq_value); \
M_64_SWAP((rp)->seq_max); \
M_64_SWAP((rp)->seq_min); \
} while (0)
#define SEQ_SWAP_IN(seq) \
do { \
if (__db_isbigendian()) { \
memcpy(&seq->seq_record, seq->seq_data.data, \
sizeof(seq->seq_record)); \
SEQ_SWAP(&seq->seq_record); \
} \
} while (0)
#define SEQ_SWAP_OUT(seq) \
do { \
if (__db_isbigendian()) { \
memcpy(seq->seq_data.data, \
&seq->seq_record, sizeof(seq->seq_record));\
SEQ_SWAP((DB_SEQ_RECORD*)seq->seq_data.data); \
} \
} while (0)
static int __seq_close __P((DB_SEQUENCE *, u_int32_t));
static int __seq_get __P((DB_SEQUENCE *,
DB_TXN *, int32_t, db_seq_t *, u_int32_t));
static int __seq_get_cachesize __P((DB_SEQUENCE *, int32_t *));
static int __seq_get_flags __P((DB_SEQUENCE *, u_int32_t *));
static int __seq_get_key __P((DB_SEQUENCE *, DBT *));
static int __seq_get_range __P((DB_SEQUENCE *, db_seq_t *, db_seq_t *));
static int __seq_set_range __P((DB_SEQUENCE *, db_seq_t, db_seq_t));
static int __seq_get_db __P((DB_SEQUENCE *, DB **));
static int __seq_initial_value __P((DB_SEQUENCE *, db_seq_t));
static int __seq_open __P((DB_SEQUENCE *, DB_TXN *, DBT *, u_int32_t));
static int __seq_remove __P((DB_SEQUENCE *, DB_TXN *, u_int32_t));
static int __seq_set_cachesize __P((DB_SEQUENCE *, int32_t));
static int __seq_set_flags __P((DB_SEQUENCE *, u_int32_t));
static int __seq_update __P((DB_SEQUENCE *, DB_TXN *, int32_t, u_int32_t));
/*
* db_sequence_create --
* DB_SEQUENCE constructor.
*
* EXTERN: int db_sequence_create __P((DB_SEQUENCE **, DB *, u_int32_t));
*/
int
db_sequence_create(seqp, dbp, flags)
DB_SEQUENCE **seqp;
DB *dbp;
u_int32_t flags;
{
DB_ENV *dbenv;
DB_SEQUENCE *seq;
int ret;
dbenv = dbp->dbenv;
/* Check for invalid function flags. */
switch (flags) {
case 0:
break;
default:
return (__db_ferr(dbenv, "db_sequence_create", 0));
}
DB_ILLEGAL_BEFORE_OPEN(dbp, "db_sequence_create");
/* Allocate the sequence. */
if ((ret = __os_calloc(dbenv, 1, sizeof(*seq), &seq)) != 0)
return (ret);
seq->seq_dbp = dbp;
seq->close = __seq_close;
seq->get = __seq_get;
seq->get_cachesize = __seq_get_cachesize;
seq->set_cachesize = __seq_set_cachesize;
seq->get_db = __seq_get_db;
seq->get_flags = __seq_get_flags;
seq->get_key = __seq_get_key;
seq->get_range = __seq_get_range;
seq->initial_value = __seq_initial_value;
seq->open = __seq_open;
seq->remove = __seq_remove;
seq->set_flags = __seq_set_flags;
seq->set_range = __seq_set_range;
seq->stat = __seq_stat;
seq->stat_print = __seq_stat_print;
seq->seq_rp = &seq->seq_record;
*seqp = seq;
return (0);
}
/*
* __seq_open --
* DB_SEQUENCE->open method.
*
*/
static int
__seq_open(seq, txn, keyp, flags)
DB_SEQUENCE *seq;
DB_TXN *txn;
DBT *keyp;
u_int32_t flags;
{
DB *dbp;
DB_ENV *dbenv;
DB_MPOOL *dbmp;
DB_SEQ_RECORD *rp;
u_int32_t tflags;
int txn_local, ret;
#define SEQ_OPEN_FLAGS (DB_AUTO_COMMIT | DB_CREATE | DB_EXCL | DB_THREAD)
dbp = seq->seq_dbp;
dbenv = dbp->dbenv;
txn_local = 0;
SEQ_ILLEGAL_AFTER_OPEN(seq, "DB_SEQUENCE->open");
if (keyp->size == 0) {
__db_err(dbenv, "Zero length sequence key specified");
return (EINVAL);
}
if (LF_ISSET(~SEQ_OPEN_FLAGS))
return (__db_ferr(dbenv, "DB_SEQUENCE->open", 0));
if ((ret = dbp->get_flags(dbp, &tflags)) != 0)
return (ret);
if (FLD_ISSET(tflags, DB_DUP)) {
__db_err(dbenv,
"Sequences not supported in databases configured for duplicate data");
return (EINVAL);
}
if (LF_ISSET(DB_THREAD)) {
dbmp = dbenv->mp_handle;
if ((ret = __db_mutex_setup(dbenv, dbmp->reginfo,
&seq->seq_mutexp, MUTEX_ALLOC | MUTEX_THREAD)) != 0)
return (ret);
}
memset(&seq->seq_data, 0, sizeof(DBT));
if (__db_isbigendian()) {
if ((ret = __os_umalloc(dbenv,
sizeof(seq->seq_record), &seq->seq_data.data)) != 0)
goto err;
seq->seq_data.flags = DB_DBT_REALLOC;
} else {
seq->seq_data.data = &seq->seq_record;
seq->seq_data.flags = DB_DBT_USERMEM;
}
seq->seq_data.ulen = seq->seq_data.size = sizeof(seq->seq_record);
seq->seq_rp = &seq->seq_record;
memset(&seq->seq_key, 0, sizeof(DBT));
if ((ret = __os_malloc(dbenv, keyp->size, &seq->seq_key.data)) != 0)
return (ret);
memcpy(seq->seq_key.data, keyp->data, keyp->size);
seq->seq_key.size = seq->seq_key.ulen = keyp->size;
seq->seq_key.flags = DB_DBT_USERMEM;
retry: if ((ret = dbp->get(dbp, txn, &seq->seq_key, &seq->seq_data, 0)) != 0) {
if (ret == DB_BUFFER_SMALL &&
seq->seq_data.size > sizeof(seq->seq_record)) {
seq->seq_data.flags = DB_DBT_REALLOC;
seq->seq_data.data = NULL;
goto retry;
}
if ((ret != DB_NOTFOUND && ret != DB_KEYEMPTY) ||
!LF_ISSET(DB_CREATE))
goto err;
ret = 0;
rp = &seq->seq_record;
tflags = DB_NOOVERWRITE;
tflags |= LF_ISSET(DB_AUTO_COMMIT);
if (!F_ISSET(rp, DB_SEQ_RANGE_SET)) {
rp->seq_max = INT64_MAX;
rp->seq_min = INT64_MIN;
}
/* INC is the default. */
if (!F_ISSET(rp, DB_SEQ_DEC))
F_SET(rp, DB_SEQ_INC);
rp->seq_version = DB_SEQUENCE_VERSION;
if (rp->seq_value > rp->seq_max ||
rp->seq_value < rp->seq_min) {
__db_err(dbenv, "Sequence value out of range");
ret = EINVAL;
goto err;
} else {
SEQ_SWAP_OUT(seq);
if ((ret = dbp->put(dbp, txn,
&seq->seq_key, &seq->seq_data, tflags)) != 0) {
__db_err(dbenv, "Sequence create failed");
goto err;
}
}
} else if (LF_ISSET(DB_CREATE) && LF_ISSET(DB_EXCL)) {
ret = EEXIST;
goto err;
} else if (seq->seq_data.size < sizeof(seq->seq_record)) {
__db_err(dbenv, "Bad sequence record format");
ret = EINVAL;
goto err;
}
if (!__db_isbigendian())
seq->seq_rp = seq->seq_data.data;
/*
* The first release was stored in native mode.
* Check the verison number before swapping.
*/
rp = seq->seq_data.data;
if (rp->seq_version == DB_SEQUENCE_OLDVER) {
oldver: rp->seq_version = DB_SEQUENCE_VERSION;
if (__db_isbigendian()) {
if (IS_AUTO_COMMIT(dbp, txn, flags)) {
if ((ret =
__db_txn_auto_init(dbenv, &txn)) != 0)
return (ret);
txn_local = 1;
LF_CLR(DB_AUTO_COMMIT);
goto retry;
} else
txn_local = 0;
memcpy(&seq->seq_record, rp, sizeof(seq->seq_record));
SEQ_SWAP_OUT(seq);
}
if ((ret = dbp->put(dbp,
txn, &seq->seq_key, &seq->seq_data, 0)) != 0)
goto err;
}
rp = seq->seq_rp;
SEQ_SWAP_IN(seq);
if (rp->seq_version != DB_SEQUENCE_VERSION) {
/*
* The database may have moved from one type
* of machine to another, check here.
* If we moved from little-end to big-end then
* the swap above will make the version correct.
* If the move was from big to little
* then we need to swap to see if this
* is an old version.
*/
if (rp->seq_version == DB_SEQUENCE_OLDVER)
goto oldver;
M_32_SWAP(rp->seq_version);
if (rp->seq_version == DB_SEQUENCE_OLDVER) {
SEQ_SWAP(rp);
goto oldver;
}
M_32_SWAP(rp->seq_version);
__db_err(dbenv,
"Unknown sequence version: %d", rp->seq_version);
goto err;
}
seq->seq_last_value = rp->seq_value;
if (F_ISSET(rp, DB_SEQ_INC))
seq->seq_last_value--;
else
seq->seq_last_value++;
err: if (ret != 0) {
__os_free(dbenv, seq->seq_key.data);
seq->seq_key.data = NULL;
}
return (txn_local ? __db_txn_auto_resolve(dbenv, txn, 0, ret) : ret);
}
/*
* __seq_get_cachesize --
* Accessor for value passed into DB_SEQUENCE->set_cachesize call.
*
*/
static int
__seq_get_cachesize(seq, cachesize)
DB_SEQUENCE *seq;
int32_t *cachesize;
{
SEQ_ILLEGAL_BEFORE_OPEN(seq, "DB_SEQUENCE->get_cachesize");
*cachesize = seq->seq_cache_size;
return (0);
}
/*
* __seq_set_cachesize --
* DB_SEQUENCE->set_cachesize.
*
*/
static int
__seq_set_cachesize(seq, cachesize)
DB_SEQUENCE *seq;
int32_t cachesize;
{
if (cachesize < 0) {
__db_err(seq->seq_dbp->dbenv,
"Illegal cache size: %d", cachesize);
return (EINVAL);
}
seq->seq_cache_size = cachesize;
return (0);
}
#define SEQ_SET_FLAGS (DB_SEQ_WRAP | DB_SEQ_INC | DB_SEQ_DEC)
/*
* __seq_get_flags --
* Accessor for flags passed into DB_SEQUENCE->open call
*
*/
static int
__seq_get_flags(seq, flagsp)
DB_SEQUENCE *seq;
u_int32_t *flagsp;
{
SEQ_ILLEGAL_BEFORE_OPEN(seq, "DB_SEQUENCE->get_flags");
*flagsp = F_ISSET(seq->seq_rp, SEQ_SET_FLAGS);
return (0);
}
/*
* __seq_set_flags --
* DB_SEQUENCE->set_flags.
*
*/
static int
__seq_set_flags(seq, flags)
DB_SEQUENCE *seq;
u_int32_t flags;
{
DB_ENV *dbenv;
DB_SEQ_RECORD *rp;
int ret;
dbenv = seq->seq_dbp->dbenv;
rp = seq->seq_rp;
SEQ_ILLEGAL_AFTER_OPEN(seq, "DB_SEQUENCE->set_flags");
if (LF_ISSET(~SEQ_SET_FLAGS))
return (__db_ferr(dbenv, "DB_SEQUENCE->set_flags", 0));
if ((ret = __db_fcchk(dbenv,
"DB_SEQUENCE->set_flags", flags, DB_SEQ_DEC, DB_SEQ_INC)) != 0)
return (ret);
if (LF_ISSET(DB_SEQ_DEC | DB_SEQ_INC))
F_CLR(rp, DB_SEQ_DEC | DB_SEQ_INC);
F_SET(rp, flags);
return (0);
}
/*
* __seq_initial_value --
* DB_SEQUENCE->init_value.
*
*/
static int
__seq_initial_value(seq, value)
DB_SEQUENCE *seq;
db_seq_t value;
{
DB_ENV *dbenv;
DB_SEQ_RECORD *rp;
dbenv = seq->seq_dbp->dbenv;
SEQ_ILLEGAL_AFTER_OPEN(seq, "DB_SEQUENCE->init_value");
rp = seq->seq_rp;
if (F_ISSET(rp, DB_SEQ_RANGE_SET) &&
(value > rp->seq_max || value < rp->seq_min)) {
__db_err(dbenv, "Sequence value out of range");
return (EINVAL);
}
rp->seq_value = value;
return (0);
}
/*
* __seq_get_range --
* Accessor for range passed into DB_SEQUENCE->set_range call
*
*/
static int
__seq_get_range(seq, minp, maxp)
DB_SEQUENCE *seq;
db_seq_t *minp, *maxp;
{
SEQ_ILLEGAL_BEFORE_OPEN(seq, "DB_SEQUENCE->get_range");
F_SET(seq->seq_rp, DB_SEQ_RANGE_SET);
*minp = seq->seq_rp->seq_min;
*maxp = seq->seq_rp->seq_max;
return (0);
}
/*
* __seq_set_range --
* SEQUENCE->set_range.
*
*/
static int
__seq_set_range(seq, min, max)
DB_SEQUENCE *seq;
db_seq_t min, max;
{
DB_ENV *dbenv;
dbenv = seq->seq_dbp->dbenv;
SEQ_ILLEGAL_AFTER_OPEN(seq, "DB_SEQUENCE->set_range");
if (min >= max) {
__db_err(dbenv, "Illegal sequence range");
return (EINVAL);
}
seq->seq_rp->seq_min = min;
seq->seq_rp->seq_max = max;
F_SET(seq->seq_rp, DB_SEQ_RANGE_SET);
return (0);
}
static int
__seq_update(seq, txn, delta, flags)
DB_SEQUENCE *seq;
DB_TXN *txn;
int32_t delta;
u_int32_t flags;
{
DB *dbp;
DB_ENV *dbenv;
DB_SEQ_RECORD *rp;
int32_t adjust;
int ret;
dbp = seq->seq_dbp;
dbenv = dbp->dbenv;
if (LF_ISSET(DB_AUTO_COMMIT) &&
(ret = __db_txn_auto_init(dbenv, &txn)) != 0)
return (ret);
retry:
if ((ret = dbp->get(dbp, txn, &seq->seq_key, &seq->seq_data, 0)) != 0) {
if (ret == DB_BUFFER_SMALL &&
seq->seq_data.size > sizeof(seq->seq_record)) {
seq->seq_data.flags = DB_DBT_REALLOC;
seq->seq_data.data = NULL;
goto retry;
}
goto err;
}
if (!__db_isbigendian())
seq->seq_rp = seq->seq_data.data;
SEQ_SWAP_IN(seq);
rp = seq->seq_rp;
if (seq->seq_data.size < sizeof(seq->seq_record)) {
__db_err(dbenv, "Bad sequence record format");
ret = EINVAL;
goto err;
}
adjust = delta > seq->seq_cache_size ? delta : seq->seq_cache_size;
/*
* Check whether this operation will cause the sequence to wrap.
*
* The sequence minimum and maximum values can be INT64_MIN and
* INT64_MAX, so we need to do the test carefully to cope with
* arithmetic overflow. That means we need to check whether the value
* is in a range, we can't get away with a single comparison.
*
* For example, if seq_value == -1 and seq_max == INT64_MAX, the first
* test below will be true, since -1 - (INT64_MAX + 1) == INT64_MAX.
* The second part of the test makes sure that seq_value is close
* enough to the maximum to really cause wrapping.
*/
if (F_ISSET(rp, DB_SEQ_INC)) {
if (rp->seq_value - ((rp->seq_max - adjust) + 2) >= 0 &&
(rp->seq_max + 1) - rp->seq_value >= 0) {
if (F_ISSET(rp, DB_SEQ_WRAP))
rp->seq_value = rp->seq_min;
else {
overflow: __db_err(dbenv, "Sequence overflow");
ret = EINVAL;
goto err;
}
}
} else {
if (rp->seq_value - (rp->seq_min - 1) >= 0 &&
(rp->seq_min + adjust - 2) - rp->seq_value >= 0) {
if (F_ISSET(rp, DB_SEQ_WRAP))
rp->seq_value = rp->seq_max;
else
goto overflow;
}
adjust = -adjust;
}
rp->seq_value += adjust;
SEQ_SWAP_OUT(seq);
ret = dbp->put(dbp, txn, &seq->seq_key, &seq->seq_data, 0);
rp->seq_value -= adjust;
if (ret != 0) {
__db_err(dbenv, "Sequence update failed");
goto err;
}
seq->seq_last_value = rp->seq_value + adjust;
if (F_ISSET(rp, DB_SEQ_INC))
seq->seq_last_value--;
else
seq->seq_last_value++;
err: if (LF_ISSET(DB_AUTO_COMMIT))
ret = __db_txn_auto_resolve(dbenv,
txn, LF_ISSET(DB_TXN_NOSYNC), ret);
return (ret);
}
static int
__seq_get(seq, txn, delta, retp, flags)
DB_SEQUENCE *seq;
DB_TXN *txn;
int32_t delta;
db_seq_t *retp;
u_int32_t flags;
{
DB *dbp;
DB_ENV *dbenv;
DB_SEQ_RECORD *rp;
int ret;
dbp = seq->seq_dbp;
dbenv = dbp->dbenv;
rp = seq->seq_rp;
ret = 0;
SEQ_ILLEGAL_BEFORE_OPEN(seq, "DB_SEQUENCE->get");
if (delta <= 0) {
__db_err(dbenv, "Sequence delta must be greater than 0");
return (EINVAL);
}
MUTEX_THREAD_LOCK(dbenv, seq->seq_mutexp);
if (rp->seq_min + delta > rp->seq_max) {
__db_err(dbenv, "Sequence overflow");
ret = EINVAL;
goto err;
}
if (F_ISSET(rp, DB_SEQ_INC)) {
if (seq->seq_last_value + 1 - rp->seq_value < delta &&
(ret = __seq_update(seq, txn, delta, flags)) != 0)
goto err;
rp = seq->seq_rp;
*retp = rp->seq_value;
rp->seq_value += delta;
} else {
if ((rp->seq_value - seq->seq_last_value) + 1 < delta &&
(ret = __seq_update(seq, txn, delta, flags)) != 0)
goto err;
rp = seq->seq_rp;
*retp = rp->seq_value;
rp->seq_value -= delta;
}
err: MUTEX_THREAD_UNLOCK(dbenv, seq->seq_mutexp);
return (ret);
}
/*
* __seq_get_db --
* Accessor for dbp passed into DB_SEQUENCE->open call
*
*/
static int
__seq_get_db(seq, dbpp)
DB_SEQUENCE *seq;
DB **dbpp;
{
SEQ_ILLEGAL_BEFORE_OPEN(seq, "DB_SEQUENCE->get_db");
*dbpp = seq->seq_dbp;
return (0);
}
/*
* __seq_get_key --
* Accessor for key passed into DB_SEQUENCE->open call
*
*/
static int
__seq_get_key(seq, key)
DB_SEQUENCE *seq;
DBT *key;
{
SEQ_ILLEGAL_BEFORE_OPEN(seq, "DB_SEQUENCE->get_key");
key->data = seq->seq_key.data;
key->size = key->ulen = seq->seq_key.size;
key->flags = seq->seq_key.flags;
return (0);
}
/*
* __seq_close --
* Close a sequence
*
*/
static int
__seq_close(seq, flags)
DB_SEQUENCE *seq;
u_int32_t flags;
{
DB_ENV *dbenv;
DB_MPOOL *dbmp;
int ret;
ret = 0;
dbenv = seq->seq_dbp->dbenv;
if (flags != 0)
ret = __db_ferr(dbenv, "DB_SEQUENCE->close", 0);
if (seq->seq_mutexp != NULL) {
dbmp = dbenv->mp_handle;
__db_mutex_free(dbenv, dbmp->reginfo, seq->seq_mutexp);
}
if (seq->seq_key.data != NULL)
__os_free(dbenv, seq->seq_key.data);
if (seq->seq_data.data != NULL &&
seq->seq_data.data != &seq->seq_record)
__os_ufree(dbenv, seq->seq_data.data);
seq->seq_key.data = NULL;
memset(seq, CLEAR_BYTE, sizeof(*seq));
__os_free(dbenv, seq);
return (ret);
}
/*
* __seq_remove --
* Remove a sequence from the database.
*/
static int
__seq_remove(seq, txn, flags)
DB_SEQUENCE *seq;
DB_TXN *txn;
u_int32_t flags;
{
DB *dbp;
DB_ENV *dbenv;
int ret, t_ret;
dbp = seq->seq_dbp;
dbenv = dbp->dbenv;
SEQ_ILLEGAL_BEFORE_OPEN(seq, "DB_SEQUENCE->remove");
if (LF_ISSET(DB_AUTO_COMMIT) &&
(ret = __db_txn_auto_init(dbenv, &txn)) != 0)
goto err;
ret = dbp->del(dbp, txn, &seq->seq_key, 0);
if (LF_ISSET(DB_AUTO_COMMIT))
ret = __db_txn_auto_resolve(dbenv,
txn, LF_ISSET(DB_TXN_NOSYNC), ret);
err: if ((t_ret = __seq_close(seq, 0)) != 0 && ret == 0)
ret = t_ret;
return (ret);
}
#else /* !HAVE_SEQUENCE */
int
db_sequence_create(seqp, dbp, flags)
DB_SEQUENCE **seqp;
DB *dbp;
u_int32_t flags;
{
COMPQUIET(seqp, NULL);
COMPQUIET(flags, 0);
__db_err(dbp->dbenv,
"library build did not include support for sequences");
return (DB_OPNOTSUP);
}
#endif /* HAVE_SEQUENCE */