From e7905fdf275fbb520de97df1eccdcd20e3d9aa6f Mon Sep 17 00:00:00 2001 From: EuAndreh Date: Fri, 25 Oct 2024 10:19:35 -0300 Subject: Move code to src/ and tests/ --- bolt_openbsd.go | 27 --------------------------- 1 file changed, 27 deletions(-) delete mode 100644 bolt_openbsd.go (limited to 'bolt_openbsd.go') diff --git a/bolt_openbsd.go b/bolt_openbsd.go deleted file mode 100644 index 7058c3d..0000000 --- a/bolt_openbsd.go +++ /dev/null @@ -1,27 +0,0 @@ -package bolt - -import ( - "syscall" - "unsafe" -) - -const ( - msAsync = 1 << iota // perform asynchronous writes - msSync // perform synchronous writes - msInvalidate // invalidate cached data -) - -func msync(db *DB) error { - _, _, errno := syscall.Syscall(syscall.SYS_MSYNC, uintptr(unsafe.Pointer(db.data)), uintptr(db.datasz), msInvalidate) - if errno != 0 { - return errno - } - return nil -} - -func fdatasync(db *DB) error { - if db.data != nil { - return msync(db) - } - return db.file.Sync() -} -- cgit v1.2.3