Validate sqlite header

This commit is contained in:
Ben Johnson
2020-11-06 12:33:01 -07:00
parent 9a2a30f239
commit d964e4199a
8 changed files with 235 additions and 149 deletions

View File

@@ -69,6 +69,13 @@ func (f *FileSystem) Open() error {
})
}
// DB returns the DB object associated with path.
func (f *FileSystem) DB(path string) *DB {
f.mu.RLock()
defer f.mu.RUnlock()
return f.dbs[path]
}
// OpenDB initializes a DB for a given path.
func (f *FileSystem) OpenDB(path string) error {
f.mu.Lock()