rc = sqliteOsTruncate(&pPager->fd, SQLITE_PAGE_SIZE*(off_t)pPager->ckptSize);
rc = sqliteOsTruncate(&pPager->fd, SQLITE_PAGE_SIZE*(OFF_T)pPager->ckptSize);
static int pager_ckpt_playback(Pager *pPager){  off_t szJ;               /* Size of the full journal */  int nRec;                /* Number of Records */  int i;                   /* Loop counter */  int rc;  /* Truncate the database back to its original size.  */  rc = sqliteOsTruncate(&pPager->fd, SQLITE_PAGE_SIZE*(off_t)pPager->ckptSize);  pPager->dbSize = pPager->ckptSize;  /* Figure out how many records are in the checkpoint journal.  */  assert( pPager->ckptInUse && pPager->journalOpen );  sqliteOsSeek(&pPager->cpfd, 0);  nRec = pPager->ckptNRec;    /* Copy original pages out of the checkpoint journal and back into the  ** database file.  Note that the checkpoint journal always uses format  ** 2 instead of format 3 since it does not need to be concerned with  ** power failures corrupting the journal and can thus omit the checksums.  */  for(i=nRec-1; i>=0; i--){    rc = pager_playback_one_page(pPager, &pPager->cpfd, 2);    assert( rc!=SQLITE_DONE );    if( rc!=SQLITE_OK ) goto end_ckpt_playback;  }  /* Figure out how many pages need to be copied out of the transaction  ** journal.  */  rc = sqliteOsSeek(&pPager->jfd, pPager->ckptJSize);  if( rc!=SQLITE_OK ){    goto end_ckpt_playback;  }  rc = sqliteOsFileSize(&pPager->jfd, &szJ);  if( rc!=SQLITE_OK ){    goto end_ckpt_playback;  }  nRec = (szJ - pPager->ckptJSize)/JOURNAL_PG_SZ(journal_format);  for(i=nRec-1; i>=0; i--){    rc = pager_playback_one_page(pPager, &pPager->jfd, journal_format);    if( rc!=SQLITE_OK ){      assert( rc!=SQLITE_DONE );      goto end_ckpt_playback;    }  }  end_ckpt_playback:  if( rc!=SQLITE_OK ){    pPager->errMask |= PAGER_ERR_CORRUPT;    rc = SQLITE_CORRUPT;  }  return rc;}