[bugfix] add all possible busy result codes to the sqlite errBusy catching check (#2775)
This commit is contained in:
parent
967558947a
commit
0767647056
|
@ -72,7 +72,9 @@ func processSQLiteError(err error) error {
|
|||
case sqlite3.SQLITE_CONSTRAINT_UNIQUE,
|
||||
sqlite3.SQLITE_CONSTRAINT_PRIMARYKEY:
|
||||
return db.ErrAlreadyExists
|
||||
case sqlite3.SQLITE_BUSY:
|
||||
case sqlite3.SQLITE_BUSY,
|
||||
sqlite3.SQLITE_BUSY_SNAPSHOT,
|
||||
sqlite3.SQLITE_BUSY_RECOVERY:
|
||||
return errBusy
|
||||
case sqlite3.SQLITE_BUSY_TIMEOUT:
|
||||
return db.ErrBusyTimeout
|
||||
|
|
Loading…
Reference in New Issue