Lines Matching refs:aData
50182 static u32 pager_cksum(Pager *pPager, const u8 *aData){
50186 cksum += aData[i];
50269 char *aData; /* Temporary storage for the page */
50283 aData = pPager->pTmpSpace;
50284 assert( aData ); /* Temp storage must have already been allocated */
50304 rc = sqlite3OsRead(jfd, (u8*)aData, pPager->pageSize, (*pOffset)+4);
50323 if( !isSavepnt && pager_cksum(pPager, (u8*)aData)!=cksum ){
50337 if( pgno==1 && pPager->nReserve!=((u8*)aData)[20] ){
50338 pPager->nReserve = ((u8*)aData)[20];
50385 PAGERID(pPager), pgno, pager_datahash(pPager->pageSize, (u8*)aData),
50409 CODEC2(pPager, aData, pgno, 7, rc=SQLITE_NOMEM_BKPT, aData);
50410 rc = sqlite3OsWrite(pPager->fd, (u8 *)aData, pPager->pageSize, ofst);
50411 CODEC1(pPager, aData, pgno, 3, rc=SQLITE_NOMEM_BKPT);
50414 rc = sqlite3OsWrite(pPager->fd, (u8 *)aData, pPager->pageSize, ofst);
50422 CODEC1(pPager, aData, pgno, 3, rc=SQLITE_NOMEM_BKPT);
50423 sqlite3BackupUpdate(pPager->pBackup, pgno, (u8*)aData);
50424 CODEC2(pPager, aData, pgno, 7, rc=SQLITE_NOMEM_BKPT,aData);
50427 sqlite3BackupUpdate(pPager->pBackup, pgno, (u8*)aData);
50464 memcpy(pData, (u8*)aData, pPager->pageSize);
54982 void *aData = 0;
54983 CODEC2(pPg->pPager, pPg->pData, pPg->pgno, 6, return 0, aData);
54984 return aData;
56262 u32 *aData = (u32 *)a;
56277 s1 += *aData++ + s2;
56278 s2 += *aData++ + s1;
56279 }while( aData<aEnd );
56282 s1 += BYTESWAP32(aData[0]) + s2;
56283 s2 += BYTESWAP32(aData[1]) + s1;
56284 aData += 2;
56285 }while( aData<aEnd );
56333 u8 *aData, /* Pointer to page data */
56346 walChecksumBytes(nativeCksum, aData, pWal->szPage, aCksum, aCksum);
56364 u8 *aData, /* Pointer to page data (for checksum) */
56393 walChecksumBytes(nativeCksum, aData, pWal->szPage, aCksum, aCksum);
56765 u8 *aData; /* Pointer to data part of aFrame buffer */
56823 aData = &aFrame[WAL_FRAME_HDRSIZE];
56835 isValid = walDecodeFrame(pWal, &pgno, &nTruncate, aData, aFrame);
57842 u8 *aData; /* Pointer to data part of aFrame buffer */
57935 aData = &aFrame[WAL_FRAME_HDRSIZE];
57953 if( !walDecodeFrame(pWal, &pgno, &nTruncate, aData, aFrame) ) break;
59715 u8 *aData; /* Pointer to disk image of the page data */
61486 ((P)->aData + ((P)->maskPage & get2byteAligned(&(P)->aCellIdx[2*(I)])))
61815 src = data = pPage->aData;
61937 u8 * const aData = pPg->aData;
61939 int pc = get2byte(&aData[iAddr]);
61949 size = get2byte(&aData[pc+2]);
61959 if( aData[hdr+7]>57 ) return 0;
61963 memcpy(&aData[iAddr], &aData[pc], 2);
61964 aData[hdr+7] += (u8)x;
61968 put2byte(&aData[pc+2], x);
61970 return &aData[pc + x];
61973 pc = get2byte(&aData[pc]);
61998 u8 * const data = pPage->aData; /* Local cache of pPage->aData */
62094 unsigned char *data = pPage->aData; /* Page content */
62267 assert( pPage->aData == sqlite3PagerGetData(pPage->pDbPage) );
62272 data = pPage->aData;
62389 unsigned char *data = pPage->aData;
62428 pPage->aData = sqlite3PagerGetData(pDbPage);
62434 assert( pPage->aData==sqlite3PagerGetData(pDbPage) );
62539 assert( (*ppPage)->aData==sqlite3PagerGetData(pDbPage) );
62567 assert( pPage->aData );
62571 assert( sqlite3PagerGetData(pPage->pDbPage)==pPage->aData );
62580 assert( pPage->aData );
62584 assert( sqlite3PagerGetData(pPage->pDbPage)==pPage->aData );
63419 nPage = nPageHeader = get4byte(28+(u8*)pPage1->aData);
63421 if( nPage==0 || memcmp(24+(u8*)pPage1->aData, 92+(u8*)pPage1->aData,4)!=0 ){
63427 u8 *page1 = pPage1->aData;
63610 assert( pPage1->aData );
63633 data = pP1->aData;
63826 if( pBt->nPage!=get4byte(&pPage1->aData[28]) ){
63829 put4byte(&pPage1->aData[28], pBt->nPage);
63881 Pgno childPgno = get4byte(&pPage->aData[pPage->hdrOffset+8]);
63907 if( get4byte(pPage->aData)!=iFrom ){
63910 put4byte(pPage->aData, iTo);
63926 if( pCell+info.nSize > pPage->aData+pPage->pBt->usableSize ){
63944 get4byte(&pPage->aData[pPage->hdrOffset+8])!=iFrom ){
63947 put4byte(&pPage->aData[pPage->hdrOffset+8], iTo);
64004 Pgno nextOvfl = get4byte(pDbPage->aData);
64067 nFreeList = get4byte(&pBt->pPage1->aData[36]);
64188 Pgno nFree = get4byte(&pBt->pPage1->aData[36]);
64201 put4byte(&pBt->pPage1->aData[28], pBt->nPage);
64243 nFree = get4byte(&pBt->pPage1->aData[36]);
64254 put4byte(&pBt->pPage1->aData[32], 0);
64255 put4byte(&pBt->pPage1->aData[36], 0);
64256 put4byte(&pBt->pPage1->aData[28], nFin);
64530 int nPage = get4byte(28+(u8*)pPage1->aData);
64614 pBt->nPage = get4byte(28 + pBt->pPage1->aData);
64694 assert( pBt->pPage1 && pBt->pPage1->aData );
64867 (i64)(pCur->info.pPayload - pCur->pPage->aData);
64950 next = get4byte(pPage->aData);
65050 assert( aPayload > pPage->aData );
65051 if( (uptr)(aPayload - pPage->aData) > (pBt->usableSize - pCur->info.nLocal) ){
65295 assert( pCur->info.pPayload>pCur->pPage->aData || CORRUPT_DB );
65369 assert( get4byte(&pParent->aData[pParent->hdrOffset+8])==iChild );
65497 subpage = get4byte(&pRoot->aData[pRoot->hdrOffset+8]);
65547 pgno = get4byte(&pPage->aData[pPage->hdrOffset+8]);
65880 chldPg = get4byte(&pPage->aData[pPage->hdrOffset+8]);
65995 rc = moveToChild(pCur, get4byte(&pPage->aData[pPage->hdrOffset+8]));
66175 n = get4byte(&pPage1->aData[36]);
66212 put4byte(&pPage1->aData[36], n-1);
66225 iTrunk = get4byte(&pPrevTrunk->aData[0]);
66230 iTrunk = get4byte(&pPage1->aData[32]);
66243 assert( pTrunk->aData!=0 );
66246 k = get4byte(&pTrunk->aData[4]);
66257 memcpy(&pPage1->aData[32], &pTrunk->aData[0], 4);
66281 memcpy(&pPage1->aData[32], &pTrunk->aData[0], 4);
66287 memcpy(&pPrevTrunk->aData[0], &pTrunk->aData[0], 4);
66295 Pgno iNewTrunk = get4byte(&pTrunk->aData[8]);
66310 memcpy(&pNewTrunk->aData[0], &pTrunk->aData[0], 4);
66311 put4byte(&pNewTrunk->aData[4], k-1);
66312 memcpy(&pNewTrunk->aData[8], &pTrunk->aData[12], (k-1)*4);
66316 put4byte(&pPage1->aData[32], iNewTrunk);
66322 put4byte(&pPrevTrunk->aData[0], iNewTrunk);
66332 unsigned char *aData = pTrunk->aData;
66338 iPage = get4byte(&aData[8+i*4]);
66346 dist = sqlite3AbsInt32(get4byte(&aData[8]) - nearby);
66348 int d2 = sqlite3AbsInt32(get4byte(&aData[8+i*4]) - nearby);
66359 iPage = get4byte(&aData[8+closest*4]);
66377 memcpy(&aData[8+closest*4], &aData[4+k*4], 4);
66379 put4byte(&aData[4], k-1);
66440 put4byte(28 + (u8*)pBt->pPage1->aData, pBt->nPage);
66499 nFree = get4byte(&pPage1->aData[36]);
66500 put4byte(&pPage1->aData[36], nFree+1);
66511 memset(pPage->aData, 0, pPage->pBt->pageSize);
66532 iTrunk = get4byte(&pPage1->aData[32]);
66538 nLeaf = get4byte(&pTrunk->aData[4]);
66566 put4byte(&pTrunk->aData[4], nLeaf+1);
66567 put4byte(&pTrunk->aData[8+nLeaf*4], iPage);
66591 put4byte(pPage->aData, iTrunk);
66592 put4byte(&pPage->aData[4], 0);
66593 put4byte(&pPage1->aData[32], iPage);
66631 if( pCell+pInfo->nSize-1 > pPage->aData+pPage->maskPage ){
66717 assert( pCell<pPage->aData || pCell>=&pPage->aData[pPage->pBt->pageSize]
66802 assert( pPayload<pPage->aData || pPayload>=&pPage->aData[pBt->pageSize]
66862 assert( pPrior<pPage->aData || pPrior>=&pPage->aData[pBt->pageSize]
66868 pPrior = pOvfl->aData;
66870 pPayload = &pOvfl->aData[4];
66898 data = pPage->aData;
66998 data = pPage->aData;
67096 u8 * const aData = pPg->aData; /* Pointer to data for pPg */
67098 u8 * const pEnd = &aData[usableSize];
67104 i = get2byte(&aData[hdr+5]);
67105 memcpy(&pTmp[i], &aData[i], usableSize - i);
67110 if( SQLITE_WITHIN(pCell,aData,pEnd) ){
67111 pCell = &pTmp[pCell - aData];
67114 put2byte(pCellptr, (pData - aData));
67126 put2byte(&aData[hdr+1], 0);
67127 put2byte(&aData[hdr+3], pPg->nCell);
67128 put2byte(&aData[hdr+5], pData - aData);
67129 aData[hdr+7] = 0x00;
67168 u8 *aData = pPg->aData;
67176 if( (aData[1]==0 && aData[2]==0) || (pSlot = pageFindSlot(pPg,sz,&rc))==0 ){
67188 put2byte(pCellptr, (pSlot - aData));
67210 u8 * const aData = pPg->aData;
67211 u8 * const pEnd = &aData[pPg->pBt->usableSize];
67212 u8 * const pStart = &aData[pPg->hdrOffset + 8 + pPg->childPtrSize];
67229 assert( pFree>aData && (pFree - aData)<65536 );
67230 freeSpace(pPg, (u16)(pFree - aData), szFree);
67243 assert( pFree>aData && (pFree - aData)<65536 );
67244 freeSpace(pPg, (u16)(pFree - aData), szFree);
67268 u8 * const aData = pPg->aData;
67280 memcpy(pTmp, aData, pPg->pBt->usableSize);
67293 pData = &aData[get2byteNotZero(&aData[hdr+5])];
67333 put2byte(&aData[hdr+3], pPg->nCell);
67334 put2byte(&aData[hdr+5], pData - aData);
67340 if( SQLITE_WITHIN(pCell, aData, &aData[pPg->pBt->usableSize]) ){
67341 pCell = &pTmp[pCell - aData];
67343 assert( 0==memcmp(pCell, &aData[iOff],
67422 assert( pPage->aData[0]==(PTF_INTKEY|PTF_LEAFDATA|PTF_LEAF) );
67470 put4byte(&pParent->aData[pParent->hdrOffset+8], pgnoNew);
67513 Pgno child = get4byte(&pPage->aData[pPage->hdrOffset+8]);
67542 u8 * const aFrom = pFrom->aData;
67543 u8 * const aTo = pTo->aData;
67706 pRight = &pParent->aData[pParent->hdrOffset+8];
67745 iOff = SQLITE_PTR_TO_INT(apDiv[i]) - SQLITE_PTR_TO_INT(pParent->aData);
67752 apDiv[i] = &aOvflSpace[apDiv[i]-pParent->aData];
67803 u8 *aData = pOld->aData;
67805 u8 *piCell = aData + pOld->cellOffset;
67811 if( pOld->aData[0]!=apOld[0]->aData[0] ){
67837 b.apCell[b.nCell] = aData + (maskPage & get2byteAligned(piCell));
67847 piEnd = aData + pOld->cellOffset + 2*pOld->nCell;
67850 b.apCell[b.nCell] = aData + (maskPage & get2byteAligned(piCell));
67874 memcpy(b.apCell[b.nCell], &pOld->aData[8], 4);
68018 pageFlags = apOld[0]->aData[0];
68112 memcpy(&apNew[nNew-1]->aData[8], &pOld->aData[8], 4);
68133 u8 *aOld = pNew->aData;
68144 aOld = pOld->aData;
68186 memcpy(&pNew->aData[8], pCell, 4);
68310 (get2byte(&apNew[0]->aData[5])-apNew[0]->cellOffset-apNew[0]->nCell*2)
68320 u32 key = get4byte(&apNew[i]->aData[8]);
68421 zeroPage(pRoot, pChild->aData[0] & ~PTF_LEAF);
68422 put4byte(&pRoot->aData[pRoot->hdrOffset+8], pgnoChild);
68907 if( pCell<&pLeaf->aData[4] ) return SQLITE_CORRUPT_BKPT;
69171 rc = clearDatabasePage(pBt, get4byte(&pPage->aData[hdr+8]), 1, pnChange);
69181 zeroPage(pPage, pPage->aData[hdr] | PTF_LEAF);
69374 *pMeta = get4byte(&pBt->pPage1->aData[36 + idx*4]);
69400 pP1 = pBt->pPage1->aData;
69480 rc = moveToChild(pCur, get4byte(&pPage->aData[pPage->hdrOffset+8]));
69796 data = pPage->aData;
70057 checkList(&sCheck, 1, get4byte(&pBt->pPage1->aData[32]),
70058 get4byte(&pBt->pPage1->aData[36]));
70346 u8 *aData = pBt->pPage1->aData;
70347 if( aData[18]!=(u8)iVersion || aData[19]!=(u8)iVersion ){
70352 aData[18] = (u8)iVersion;
70353 aData[19] = (u8)iVersion;
71096 const u8 *aData
71109 rc = backupOnePage(p, iPage, aData, 1);
71118 SQLITE_PRIVATE void sqlite3BackupUpdate(sqlite3_backup *pBackup, Pgno iPage, const u8 *aData){
71119 if( pBackup ) backupUpdate(pBackup, iPage, aData);
159019 char *aData;
159112 char *aData; /* Pointer to block from malloc() */
159144 char *aData; /* Node data */
159571 p->aData = (char *)&p[1];
159583 p->aData = (char *)&p[1];
159587 p->nData += sqlite3Fts3PutVarint(&p->aData[p->nData], i);
159588 p->aData[p->nData] = '\0';
159618 assert( p->aData[p->nData]==0 );
160254 memcpy(aCopy, pList->aData, nCopy);
160950 assert( pTree->aData==(char *)&pTree[1] );
160951 pTree->aData = (char *)sqlite3_malloc(nReq);
160952 if( !pTree->aData ){
160959 nData += sqlite3Fts3PutVarint(&pTree->aData[nData], nPrefix);
160962 nData += sqlite3Fts3PutVarint(&pTree->aData[nData], nSuffix);
160963 memcpy(&pTree->aData[nData], &zTerm[nPrefix], nSuffix);
161001 pNew->aData = (char *)&pNew[1];
161035 pTree->aData[nStart] = (char)iHeight;
161036 sqlite3Fts3PutVarint(&pTree->aData[nStart+1], iLeftChild);
161070 *paRoot = &pTree->aData[nStart];
161079 rc = fts3WriteSegment(p, iNextFree, &pIter->aData[nStart], nWrite);
161103 if( p->aData!=(char *)&p[1] ){
161104 sqlite3_free(p->aData);
161148 pWriter->aData = (char *)sqlite3_malloc(p->nNodeSize);
161149 if( !pWriter->aData ) return SQLITE_NOMEM;
161178 rc = fts3WriteSegment(p, pWriter->iFree++, pWriter->aData, nData);
161217 char *aNew = sqlite3_realloc(pWriter->aData, nReq);
161219 pWriter->aData = aNew;
161225 nData += sqlite3Fts3PutVarint(&pWriter->aData[nData], nPrefix);
161226 nData += sqlite3Fts3PutVarint(&pWriter->aData[nData], nSuffix);
161227 memcpy(&pWriter->aData[nData], &zTerm[nPrefix], nSuffix);
161229 nData += sqlite3Fts3PutVarint(&pWriter->aData[nData], nDoclist);
161230 memcpy(&pWriter->aData[nData], aDoclist, nDoclist);
161278 rc = fts3WriteSegment(p, pWriter->iFree++, pWriter->aData, pWriter->nData);
161290 0, 0, 0, pWriter->nLeafData, pWriter->aData, pWriter->nData);
161302 sqlite3_free(pWriter->aData);
164357 nSkip = sqlite3Fts3GetVarint(p->pList->aData, &dummy);
164361 memcpy(pRet, &p->pList->aData[nSkip], *pnData);
178001 u8 *aData = sqlite3PagerGetData(p->pPg);
178002 u8 *aHdr = &aData[p->iPgno==1 ? 100 : 0];
178015 nUnused += get2byte(&aData[iOff+2]);
178016 iOff = get2byte(&aData[iOff]);
178036 iOff = get2byte(&aData[nHdr+i*2]);
178038 pCell->iChildPg = sqlite3Get4byte(&aData[iOff]);
178046 iOff += getVarint32(&aData[iOff], nPayload);
178049 iOff += sqlite3GetVarint(&aData[iOff], &dummy);
178064 pCell->aOvfl[0] = sqlite3Get4byte(&aData[iOff+nLocal]);
178874 u8 *aData; /* Pointer to buffer containing changeset */
181357 pRet->in.aData = (u8 *)pChangeset;
181430 pIn->aData = pIn->buf.aBuf;
181470 u8 *aData, /* Buffer containing string or blob data */
181480 memcpy(aCopy, aData, nData);
181523 eType = pIn->aData[pIn->iNext++];
181533 u8 *aVal = &pIn->aData[pIn->iNext];
181540 rc = sessionValueSetStr(apOut[i],&pIn->aData[pIn->iNext],nByte,enc);
181581 nRead += sessionVarintGet(&pIn->aData[pIn->iNext + nRead], &nCol);
181587 while( (pIn->iNext + nRead)<pIn->nData && pIn->aData[pIn->iNext + nRead] ){
181618 eType = pIn->aData[pIn->iNext + nByte++];
181621 nByte += sessionVarintGet(&pIn->aData[pIn->iNext+nByte], &n);
181659 nVarint = sessionVarintGet(&p->in.aData[p->in.iNext], &p->nCol);
181670 memcpy(&p->tblhdr.aBuf[iPK], &p->in.aData[p->in.iNext], nCopy);
181732 op = p->in.aData[p->in.iNext++];
181739 op = p->in.aData[p->in.iNext++];
181743 p->bIndirect = p->in.aData[p->in.iNext++];
181760 *paRec = &p->in.aData[p->in.iNext];
182003 eType = pInput->aData[pInput->iNext];
182020 nVar = sessionVarintGet(&pInput->aData[pInput->iNext], &nCol);
182022 sessionAppendBlob(&sPK, &pInput->aData[pInput->iNext+nVar], nCol, &rc);
182024 sessionAppendBlob(&sOut, &pInput->aData[pInput->iNext], nByte, &rc);
182037 int bIndirect = pInput->aData[pInput->iNext+1];
182044 sessionAppendBlob(&sOut, &pInput->aData[pInput->iNext], nByte, &rc);
182064 sessionAppendByte(&sOut, pInput->aData[pInput->iNext+1], &rc);
182144 sInput.aData = (u8*)pChangeset;
182631 u8 *aBlob = &pIter->in.aData[pIter->in.iCurrent];
198298 const u8 *aData,
198302 const u8 *a = aData;