mirror of
https://github.com/sqlite/sqlite.git
synced 2025-08-08 14:02:16 +03:00
Fix some signed/unsigned compiler warnings on this branch.
FossilOrigin-Name: 681d228023efb902b9039acf33600dd91f158e622d4dc0b434ed74f39ce0070a
This commit is contained in:
@@ -579,7 +579,7 @@ static void walidxSetMxFrame(WalIndexHdr *pHdr, int iWal, u32 mxFrame){
|
||||
assert( walidxGetMxFrame(pHdr, iWal)==mxFrame );
|
||||
}
|
||||
|
||||
#define walidxGetFile(pHdr) ((pHdr)->mxFrame2 >> 31)
|
||||
#define walidxGetFile(pHdr) (int)((pHdr)->mxFrame2 >> 31)
|
||||
|
||||
#define walidxSetFile(pHdr, iWal) ( \
|
||||
(pHdr)->mxFrame2 = ((pHdr)->mxFrame2 & 0x7FFFFFFF) | (((u32)(iWal))<<31) \
|
||||
@@ -4533,7 +4533,7 @@ void sqlite3WalSavepoint(Wal *pWal, u32 *aWalData){
|
||||
aWalData[0] = walidxGetMxFrame(&pWal->hdr, iWal);
|
||||
aWalData[1] = pWal->hdr.aFrameCksum[0];
|
||||
aWalData[2] = pWal->hdr.aFrameCksum[1];
|
||||
aWalData[3] = isWalMode2(pWal) ? iWal : pWal->nCkpt;
|
||||
aWalData[3] = isWalMode2(pWal) ? (u32)iWal : pWal->nCkpt;
|
||||
}
|
||||
|
||||
/*
|
||||
@@ -4545,7 +4545,7 @@ void sqlite3WalSavepoint(Wal *pWal, u32 *aWalData){
|
||||
int sqlite3WalSavepointUndo(Wal *pWal, u32 *aWalData){
|
||||
int rc = SQLITE_OK;
|
||||
int iWal = walidxGetFile(&pWal->hdr);
|
||||
int iCmp = isWalMode2(pWal) ? iWal : pWal->nCkpt;
|
||||
u32 iCmp = isWalMode2(pWal) ? (u32)iWal : pWal->nCkpt;
|
||||
|
||||
assert( pWal->writeLock );
|
||||
assert( isWalMode2(pWal) || iWal==0 );
|
||||
@@ -4590,7 +4590,7 @@ static int walRestartLog(Wal *pWal){
|
||||
|
||||
if( isWalMode2(pWal) ){
|
||||
int iApp = walidxGetFile(&pWal->hdr);
|
||||
int nWalSize = WAL_DEFAULT_WALSIZE;
|
||||
u32 nWalSize = WAL_DEFAULT_WALSIZE;
|
||||
if( pWal->mxWalSize>0 ){
|
||||
nWalSize = (pWal->mxWalSize-WAL_HDRSIZE+pWal->szPage+WAL_FRAME_HDRSIZE-1)
|
||||
/ (pWal->szPage+WAL_FRAME_HDRSIZE);
|
||||
|
Reference in New Issue
Block a user