/ Check-in [bdceca27]
Login
SQLite training in Houston TX on 2019-11-05 (details)
Part of the 2019 Tcl Conference

Many hyperlinks are disabled.
Use anonymous login to enable hyperlinks.

Overview
Comment:Since errors are ignored anyway, use sqlite3OsFileControlHint() instead of OsFileControl() to invoke the SQLITE_FCNTL_BUSY_HANDLER file-control.
Downloads: Tarball | ZIP archive | SQL archive
Timelines: family | ancestors | descendants | both | trunk
Files: files | file ages | folders
SHA1: bdceca2738eb3e8acc44d0384cf2a3a969ee8170
User & Date: dan 2012-12-05 11:30:28
Context
2012-12-05
14:31
Make sure memory is freed using a routine that is compatible with the routine used to allocate the memory. The SQLITE_MEMDEBUG compile-time option enforces this. check-in: 9f6c6885 user: drh tags: trunk
11:30
Since errors are ignored anyway, use sqlite3OsFileControlHint() instead of OsFileControl() to invoke the SQLITE_FCNTL_BUSY_HANDLER file-control. check-in: bdceca27 user: dan tags: trunk
10:01
If the atomic-write property is enabled, a transaction may be committed in journal_mode=DELETE mode without ever actually creating a journal file on disk. In this case, do not attempt to unlink() the journal file when committing the transaction. check-in: 11aa47b0 user: dan tags: trunk
Changes
Hide Diffs Unified Diffs Ignore Whitespace Patch

Changes to src/pager.c.

3482
3483
3484
3485
3486
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
  pPager->xBusyHandler = xBusyHandler;
  pPager->pBusyHandlerArg = pBusyHandlerArg;

  if( isOpen(pPager->fd) ){
    void **ap = (void **)&pPager->xBusyHandler;
    assert( ((int(*)(void *))(ap[0]))==xBusyHandler );
    assert( ap[1]==pBusyHandlerArg );
    sqlite3OsFileControl(pPager->fd, SQLITE_FCNTL_BUSYHANDLER, (void *)ap);
  }
}

/*
** Change the page size used by the Pager object. The new page size 
** is passed in *pPageSize.
**







|







3482
3483
3484
3485
3486
3487
3488
3489
3490
3491
3492
3493
3494
3495
3496
  pPager->xBusyHandler = xBusyHandler;
  pPager->pBusyHandlerArg = pBusyHandlerArg;

  if( isOpen(pPager->fd) ){
    void **ap = (void **)&pPager->xBusyHandler;
    assert( ((int(*)(void *))(ap[0]))==xBusyHandler );
    assert( ap[1]==pBusyHandlerArg );
    sqlite3OsFileControlHint(pPager->fd, SQLITE_FCNTL_BUSYHANDLER, (void *)ap);
  }
}

/*
** Change the page size used by the Pager object. The new page size 
** is passed in *pPageSize.
**