path: root/
authorJason Downs <>2008-11-30 07:29:12 (GMT)
committer Jason Downs <>2008-11-30 07:29:12 (GMT)
commit75e98477a3854da8e582493f4888b3dca8d257d4 (patch) (side-by-side diff)
treec18accfef04030f856b9d8841c90bbcefef6a2d6 /
parent5a88187f15f70c5d7914469b3e39e58259f59c01 (diff)
Implement a new basic locking mechanism for GDBM. Add _gdbm_lock_file() and
_gdbm_unlock_file(), which will try to use flock(), lockf(), and fcntl() to lock the file. From ChangeLog: * Add test for lockf. * src/lock.c: New file, adds _gdbm_unlock_file() and _gdbm_lock_file() routines. These attempt to use flock(), lockf(), and fcntl() locking. * src/proto.h: Add new prototypes. * src/systems.h: Remove file locking macros. * src/gdbmopen.c: Rewrite locking code, use _gdbm_lock_file(). * src/gdbmclose.c, src/gdbmreorg.c: Use _gdbm_unlock_file().
Diffstat (limited to '') (more/less context) (ignore whitespace changes)
1 files changed, 1 insertions, 1 deletions
diff --git a/ b/
index 453b150..594fe67 100644
--- a/
+++ b/
@@ -69,7 +69,7 @@ AC_CHECK_HEADERS([stdlib.h string.h sys/file.h unistd.h fcntl.h sys/types.h memo
AC_CHECK_LIB(dbm, main)
AC_CHECK_LIB(ndbm, main)
-AC_CHECK_FUNCS([rename ftruncate flock fsync])
+AC_CHECK_FUNCS([rename ftruncate flock lockf fsync])
if test x$mapped_io = xyes

Return to:

Send suggestions and report system problems to the System administrator.