Increase busy timeout to 5 seconds.

500ms is short enough that go-sql-test sometimes fails with "database
locked", and it's the value used by Python's sqlite3 driver.
This commit is contained in:
John Gallagher 2012-04-07 00:24:39 -04:00
parent 3abc337b8e
commit db2c00ccd8
1 changed files with 1 additions and 1 deletions

View File

@ -96,7 +96,7 @@ func (d *SQLiteDriver) Open(dsn string) (driver.Conn, error) {
return nil, errors.New("sqlite succeeded without returning a database")
}
rv = C.sqlite3_busy_timeout(db, 500)
rv = C.sqlite3_busy_timeout(db, 5000)
if rv != C.SQLITE_OK {
return nil, errors.New(C.GoString(C.sqlite3_errmsg(db)))
}