add timeout to readonly incremental connection
This commit is contained in:
parent
5f8887e8b6
commit
97fb906876
@ -202,7 +202,7 @@ func (db *Sqlite3Accessor) GetBlock(pos coords.MapBlockCoords) (*Block, error) {
|
||||
}
|
||||
|
||||
func NewSqliteAccessor(filename string) (*Sqlite3Accessor, error) {
|
||||
db, err := sql.Open("sqlite3", filename+"?mode=ro")
|
||||
db, err := sql.Open("sqlite3", filename+"?mode=ro&_timeout=2000")
|
||||
if err != nil {
|
||||
return nil, err
|
||||
}
|
||||
|
Loading…
Reference in New Issue
Block a user