| 337 | } |
| 338 | |
| 339 | static int LockError(int err, int fallback) { |
| 340 | switch (err) { |
| 341 | case EACCES: |
| 342 | case EAGAIN: |
| 343 | case ETIMEDOUT: |
| 344 | case EBUSY: |
| 345 | case EINTR: |
| 346 | case ENOLCK: |
| 347 | return SQLITE_BUSY; |
| 348 | case EPERM: |
| 349 | return SQLITE_PERM; |
| 350 | default: |
| 351 | return fallback; |
| 352 | } |
| 353 | } |
| 354 | |
| 355 | // Common I/O methods (for main database files and journals) |
| 356 |
nothing calls this directly
no outgoing calls
no test coverage detected