Lines Matching refs:nByte

2418   void (*xDlError)(sqlite3_vfs*, int nByte, char *zErrMsg);
2421 int (*xRandomness)(sqlite3_vfs*, int nByte, char *zOut);
5088 int nByte, /* Maximum length of zSql in bytes. */
5095 int nByte, /* Maximum length of zSql in bytes. */
5102 int nByte, /* Maximum length of zSql in bytes. */
5110 int nByte, /* Maximum length of zSql in bytes. */
5117 int nByte, /* Maximum length of zSql in bytes. */
5124 int nByte, /* Maximum length of zSql in bytes. */
19791 SQLITE_PRIVATE int sqlite3Utf8CharLen(const char *pData, int nByte);
21531 int nByte = sqlite3PagerMemUsed(pPager); in sqlite3_db_status() local
21533 nByte = nByte / sqlite3BtreeConnectionCount(pBt); in sqlite3_db_status()
21535 totalUsed += nByte; in sqlite3_db_status()
21551 int nByte = 0; /* Used to accumulate return value */ in sqlite3_db_status() local
21554 db->pnBytesFreed = &nByte; in sqlite3_db_status()
21560 nByte += sqlite3GlobalConfig.m.xRoundup(sizeof(HashElem)) * ( in sqlite3_db_status()
21566 nByte += sqlite3_msize(pSchema->tblHash.ht); in sqlite3_db_status()
21567 nByte += sqlite3_msize(pSchema->trigHash.ht); in sqlite3_db_status()
21568 nByte += sqlite3_msize(pSchema->idxHash.ht); in sqlite3_db_status()
21569 nByte += sqlite3_msize(pSchema->fkeyHash.ht); in sqlite3_db_status()
21583 *pCurrent = nByte; in sqlite3_db_status()
21594 int nByte = 0; /* Used to accumulate return value */ in sqlite3_db_status() local
21596 db->pnBytesFreed = &nByte; in sqlite3_db_status()
21604 *pCurrent = nByte; in sqlite3_db_status()
23159 SQLITE_PRIVATE void sqlite3OsDlError(sqlite3_vfs *pVfs, int nByte, char *zBufOut){ in sqlite3OsDlError() argument
23160 pVfs->xDlError(pVfs, nByte, zBufOut); in sqlite3OsDlError()
23169 SQLITE_PRIVATE int sqlite3OsRandomness(sqlite3_vfs *pVfs, int nByte, char *zBufOut){ in sqlite3OsRandomness() argument
23171 memset(zBufOut, 0, nByte); in sqlite3OsRandomness()
23172 if( ALWAYS(nByte>(signed)sizeof(unsigned)) ) nByte = sizeof(unsigned int); in sqlite3OsRandomness()
23173 memcpy(zBufOut, &sqlite3Config.iPrngSeed, nByte); in sqlite3OsRandomness()
23176 return pVfs->xRandomness(pVfs, nByte, zBufOut); in sqlite3OsRandomness()
23464 static void *sqlite3MemMalloc(int nByte){ return 0; } in sqlite3MemMalloc() argument
23466 static void *sqlite3MemRealloc(void *pPrior, int nByte){ return 0; } in sqlite3MemRealloc() argument
23623 static void *sqlite3MemMalloc(int nByte){ in sqlite3MemMalloc() argument
23626 testcase( ROUND8(nByte)==nByte ); in sqlite3MemMalloc()
23627 p = SQLITE_MALLOC( nByte ); in sqlite3MemMalloc()
23630 sqlite3_log(SQLITE_NOMEM, "failed to allocate %u bytes of memory", nByte); in sqlite3MemMalloc()
23635 assert( nByte>0 ); in sqlite3MemMalloc()
23636 testcase( ROUND8(nByte)!=nByte ); in sqlite3MemMalloc()
23637 p = SQLITE_MALLOC( nByte+8 ); in sqlite3MemMalloc()
23639 p[0] = nByte; in sqlite3MemMalloc()
23643 sqlite3_log(SQLITE_NOMEM, "failed to allocate %u bytes of memory", nByte); in sqlite3MemMalloc()
23695 static void *sqlite3MemRealloc(void *pPrior, int nByte){ in sqlite3MemRealloc() argument
23697 void *p = SQLITE_REALLOC(pPrior, nByte); in sqlite3MemRealloc()
23702 SQLITE_MALLOCSIZE(pPrior), nByte); in sqlite3MemRealloc()
23707 assert( pPrior!=0 && nByte>0 ); in sqlite3MemRealloc()
23708 assert( nByte==ROUND8(nByte) ); /* EV: R-46199-30249 */ in sqlite3MemRealloc()
23710 p = SQLITE_REALLOC(p, nByte+8 ); in sqlite3MemRealloc()
23712 p[0] = nByte; in sqlite3MemRealloc()
23718 sqlite3MemSize(pPrior), nByte); in sqlite3MemRealloc()
24008 static void randomFill(char *pBuf, int nByte){ in randomFill() argument
24011 y = nByte | 1; in randomFill()
24012 while( nByte >= 4 ){ in randomFill()
24018 nByte -= 4; in randomFill()
24020 while( nByte-- > 0 ){ in randomFill()
24031 static void *sqlite3MemMalloc(int nByte){ in sqlite3MemMalloc() argument
24041 nReserve = ROUND8(nByte); in sqlite3MemMalloc()
24067 mem.xBacktrace(nByte, pHdr->nBacktrace-1, &aAddr[1]); in sqlite3MemMalloc()
24075 pHdr->iSize = nByte; in sqlite3MemMalloc()
24076 adjustStats(nByte, +1); in sqlite3MemMalloc()
24079 randomFill((char*)pInt, nByte); in sqlite3MemMalloc()
24080 memset(((char*)pInt)+nByte, 0x65, nReserve-nByte); in sqlite3MemMalloc()
24132 static void *sqlite3MemRealloc(void *pPrior, int nByte){ in sqlite3MemRealloc() argument
24136 assert( (nByte & 7)==0 ); /* EV: R-46199-30249 */ in sqlite3MemRealloc()
24138 pNew = sqlite3MemMalloc(nByte); in sqlite3MemRealloc()
24140 memcpy(pNew, pPrior, (int)(nByte<pOldHdr->iSize ? nByte : pOldHdr->iSize)); in sqlite3MemRealloc()
24141 if( nByte>pOldHdr->iSize ){ in sqlite3MemRealloc()
24142 randomFill(&((char*)pNew)[pOldHdr->iSize], nByte - (int)pOldHdr->iSize); in sqlite3MemRealloc()
24555 static void memsys3OutOfMemory(int nByte){ in memsys3OutOfMemory() argument
24560 sqlite3_release_memory(nByte); in memsys3OutOfMemory()
24674 static void *memsys3MallocUnsafe(int nByte){ in memsys3MallocUnsafe() argument
24681 if( nByte<=12 ){ in memsys3MallocUnsafe()
24684 nBlock = (nByte + 11)/8; in memsys3MallocUnsafe()
25230 static void *memsys5MallocUnsafe(int nByte){ in memsys5MallocUnsafe() argument
25237 assert( nByte>0 ); in memsys5MallocUnsafe()
25240 if( nByte > 0x40000000 ) return 0; in memsys5MallocUnsafe()
25245 if( (u32)nByte>mem5.maxRequest ){ in memsys5MallocUnsafe()
25246 mem5.maxRequest = nByte; in memsys5MallocUnsafe()
25252 for(iFullSz=mem5.szAtom,iLogsize=0; iFullSz<nByte; iFullSz*=2,iLogsize++){} in memsys5MallocUnsafe()
25261 sqlite3_log(SQLITE_NOMEM, "failed to allocate %u bytes", nByte); in memsys5MallocUnsafe()
25280 mem5.totalExcess += iFullSz - nByte; in memsys5MallocUnsafe()
25462 int nByte; /* Number of bytes of memory available to this allocator */ in memsys5Init() local
25477 nByte = sqlite3GlobalConfig.nHeap; in memsys5Init()
25488 mem5.nBlock = (nByte / (mem5.szAtom+sizeof(u8))); in memsys5Init()
27478 static void sqlite3MallocAlarm(int nByte){
27481 sqlite3_release_memory(nByte);
31007 SQLITE_PRIVATE int sqlite3Utf8CharLen(const char *zIn, int nByte){
31011 if( nByte>=0 ){
31012 zTerm = &z[nByte];
31061 SQLITE_PRIVATE char *sqlite3Utf16to8(sqlite3 *db, const void *z, int nByte, u8 enc){
31065 sqlite3VdbeMemSetStr(&m, z, nByte, enc, SQLITE_STATIC);
35523 static int unixMapfile(unixFile *pFd, i64 nByte);
37214 static int unixTruncate(sqlite3_file *id, i64 nByte){
37226 nByte = ((nByte + pFile->szChunk - 1)/pFile->szChunk) * pFile->szChunk;
37229 rc = robust_ftruncate(pFile->h, nByte);
37242 if( pFile->inNormalWrite && nByte==0 ){
37252 if( nByte<pFile->mmapSize ){
37253 pFile->mmapSize = nByte;
37302 static int fcntlSizeHint(unixFile *pFile, i64 nByte){
37311 nSize = ((nByte+pFile->szChunk-1) / pFile->szChunk) * pFile->szChunk;
37348 if( pFile->mmapSizeMax>0 && nByte>pFile->mmapSize ){
37351 if( robust_ftruncate(pFile->h, nByte) ){
37357 rc = unixMapfile(pFile, nByte);
38151 int nByte = nReqRegion*szRegion; /* Minimum required file size */
38166 if( sStat.st_size<nByte ){
38186 assert( (nByte % pgsz)==0 );
38187 for(iPg=(sStat.st_size/pgsz); iPg<(nByte/pgsz); iPg++){
39796 int nByte;
39835 nByte = osReadlink(zIn, zDel, nOut-1);
39836 if( nByte<0 ){
39842 if( nByte+n+1>nOut ){
39845 memmove(&zDel[n], zDel, nByte+1);
39847 nByte += n;
39850 zDel[nByte] = '\0';
43288 int nByte;
43291 nByte = osWideCharToMultiByte(CP_UTF8, 0, zWideText, -1, 0, 0, 0, 0);
43292 if( nByte == 0 ){
43295 zText = sqlite3MallocZero( nByte );
43299 nByte = osWideCharToMultiByte(CP_UTF8, 0, zWideText, -1, zText, nByte,
43301 if( nByte == 0 ){
43315 int nByte;
43319 nByte = osMultiByteToWideChar(codepage, 0, zText, -1, NULL,
43321 if( nByte==0 ){
43324 zMbcsText = sqlite3MallocZero( nByte*sizeof(WCHAR) );
43328 nByte = osMultiByteToWideChar(codepage, 0, zText, -1, zMbcsText,
43329 nByte);
43330 if( nByte==0 ){
43344 int nByte;
43348 nByte = osWideCharToMultiByte(codepage, 0, zWideText, -1, 0, 0, 0, 0);
43349 if( nByte == 0 ){
43352 zText = sqlite3MallocZero( nByte );
43356 nByte = osWideCharToMultiByte(codepage, 0, zWideText, -1, zText,
43357 nByte, 0, 0);
43358 if( nByte == 0 ){
44487 static int winTruncate(sqlite3_file *id, sqlite3_int64 nByte){
44518 osGetCurrentProcessId(), pFile, pFile->h, nByte, pFile->locktype));
44526 nByte = ((nByte + pFile->szChunk - 1)/pFile->szChunk) * pFile->szChunk;
44539 if( winSeekFile(pFile, nByte) ){
44551 if( oldMmapSize>nByte ){
45375 int nByte /* Number of bytes to lock or unlock */
45383 pFile->hFile.h, lockType, ofst, nByte));
45387 rc = winUnlockFile(&pFile->hFile.h, ofst, 0, nByte, 0);
45392 rc = winLockFile(&pFile->hFile.h, dwFlags, ofst, 0, nByte, 0);
45818 int nByte = (iRegion+1)*szRegion; /* Minimum required file size */
45834 if( sz<nByte ){
45842 rc = winTruncate((sqlite3_file *)&pShmNode->hFile, nByte);
45871 NULL, protect, nByte, NULL
45875 NULL, protect, 0, nByte, NULL
45879 NULL, protect, 0, nByte, NULL
45883 osGetCurrentProcessId(), pShmNode->nRegion, nByte,
45989 static int winMapfile(winFile *pFd, sqlite3_int64 nByte){
45990 sqlite3_int64 nMap = nByte;
45995 osGetCurrentProcessId(), pFd, nByte));
47142 DWORD nByte;
47255 nByte = osGetFullPathNameW((LPCWSTR)zConverted, 0, 0, 0);
47256 if( nByte==0 ){
47261 nByte += 3;
47262 zTemp = sqlite3MallocZero( nByte*sizeof(zTemp[0]) );
47267 nByte = osGetFullPathNameW((LPCWSTR)zConverted, nByte, zTemp, 0);
47268 if( nByte==0 ){
47281 nByte = osGetFullPathNameA((char*)zConverted, 0, 0, 0);
47282 if( nByte==0 ){
47287 nByte += 3;
47288 zTemp = sqlite3MallocZero( nByte*sizeof(zTemp[0]) );
47293 nByte = osGetFullPathNameA((char*)zConverted, nByte, zTemp, 0);
47294 if( nByte==0 ){
47808 static void memdbDlError(sqlite3_vfs*, int nByte, char *zErrMsg);
47811 static int memdbRandomness(sqlite3_vfs*, int nByte, char *zOut);
48140 static void memdbDlError(sqlite3_vfs *pVfs, int nByte, char *zErrMsg){
48141 ORIGVFS(pVfs)->xDlError(ORIGVFS(pVfs), nByte, zErrMsg);
48162 static int memdbRandomness(sqlite3_vfs *pVfs, int nByte, char *zBufOut){
48163 return ORIGVFS(pVfs)->xRandomness(ORIGVFS(pVfs), nByte, zBufOut);
49997 static void *pcache1Alloc(int nByte){
50000 if( nByte<=pcache1.szSlot ){
50008 sqlite3StatusHighwater(SQLITE_STATUS_PAGECACHE_SIZE, nByte);
50017 p = sqlite3Malloc(nByte);
50022 sqlite3StatusHighwater(SQLITE_STATUS_PAGECACHE_SIZE, nByte);
52849 static u32 pager_datahash(int nByte, unsigned char *pData){
52852 for(i=0; i<nByte; i++){
55315 i64 nByte = 0;
55318 rc = sqlite3OsFileSize(pPager->fd, &nByte);
55338 pPager->dbSize = (Pgno)((nByte+pageSize-1)/pageSize);
59876 sqlite3_int64 nByte = sizeof(u32*)*(iPage+1);
59878 apNew = (volatile u32 **)sqlite3Realloc((void *)pWal->apWiData, nByte);
59963 int nByte, /* Bytes of content in a[]. Must be a multiple of 8. */
59969 u32 *aEnd = (u32 *)&a[nByte];
59978 assert( nByte>=8 );
59979 assert( (nByte&0x00000007)==0 );
59980 assert( nByte<=65536 );
60304 int nByte; /* Number of bytes to zero in aPgno[] */
60338 nByte = (int)((char *)sLoc.aHash - (char *)&sLoc.aPgno[iLimit+1]);
60339 memset((void *)&sLoc.aPgno[iLimit+1], 0, nByte);
60384 int nByte = (int)((u8 *)&sLoc.aHash[HASHTABLE_NSLOT]
60386 memset((void*)&sLoc.aPgno[1], 0, nByte);
60936 sqlite3_int64 nByte; /* Number of bytes to allocate */
60949 nByte = sizeof(WalIterator)
60952 p = (WalIterator *)sqlite3_malloc64(nByte);
60956 memset(p, 0, nByte);
65868 static u8 *pageFindSlot(MemPage *pPg, int nByte, int *pRc){
65874 int maxPC = pPg->pBt->usableSize - nByte; /* Max address for a usable slot */
65883 if( (x = size - nByte)>=0 ){
65916 if( pc>maxPC+nByte-4 ){
65936 static int allocateSpace(MemPage *pPage, int nByte, int *pIdx){
65946 assert( nByte>=0 ); /* Minimum cell size is 4 */
65947 assert( pPage->nFree>=nByte );
65949 assert( nByte < (int)(pPage->pBt->usableSize-8) );
65977 u8 *pSpace = pageFindSlot(pPage, nByte, &rc);
65980 assert( pSpace+nByte<=data+pPage->pBt->usableSize );
65995 testcase( gap+2+nByte==top );
65996 if( gap+2+nByte>top ){
65999 rc = defragmentPage(pPage, MIN(4, pPage->nFree - (2+nByte)));
66002 assert( gap+2+nByte<=top );
66012 top -= nByte;
66014 assert( top+nByte <= (int)pPage->pBt->usableSize );
69060 int nByte, /* Number of bytes to copy */
69070 memcpy(pPayload, pBuf, nByte);
69073 memcpy(pBuf, pPayload, nByte);
75594 i64 nByte = sqlite3BtreeGetPageSize(pFrom)*(i64)sqlite3BtreeLastPage(pFrom);
75595 rc = sqlite3OsFileControl(pFd, SQLITE_FCNTL_OVERWRITE, &nByte);
75981 int nByte;
75989 nByte = pMem->n + pMem->u.nZero;
75990 if( nByte<=0 ){
75992 nByte = 1;
75994 if( sqlite3VdbeMemGrow(pMem, nByte, 1) ){
76034 const int nByte = 32;
76044 if( sqlite3VdbeMemClearAndResize(pMem, nByte) ){
76049 vdbeMemRenderNum(nByte, pMem->z, pMem);
76702 int nByte = n; /* New value for pMem->n */
76721 if( nByte<0 ){
76724 nByte = 0x7fffffff & (int)strlen(z);
76726 for(nByte=0; nByte<=iLimit && (z[nByte] | z[nByte+1]); nByte+=2){}
76736 u32 nAlloc = nByte;
76740 if( nByte>iLimit ){
76762 pMem->n = nByte;
76781 if( nByte>iLimit ){
76957 int nByte; /* Bytes of space to allocate */
76961 nByte = sizeof(Mem) * nCol + ROUND8(sizeof(UnpackedRecord));
76962 pRec = (UnpackedRecord*)sqlite3DbMallocZero(db, nByte);
77897 int nByte;
77901 nByte = sizeof(*pCtx) + (nArg-1)*sizeof(sqlite3_value*);
77902 pCtx = sqlite3DbMallocRawNN(pParse->db, nByte);
78183 int nByte = (p->nSub+1)*sizeof(SubProgram*);
78189 p->apSub = sqlite3DbReallocOrFree(v->db, p->apSub, nByte);
78558 sqlite3_int64 nByte = (p->nScan+1) * sizeof(ScanStatus);
78560 aNew = (ScanStatus*)sqlite3DbRealloc(p->db, p->aScan, nByte);
79559 int nByte = (nSub+1)*sizeof(SubProgram*);
79565 p->rc = sqlite3VdbeMemGrow(pSub, nByte, nSub!=0);
79804 sqlite3_int64 nByte /* Bytes of memory needed */
79808 nByte = ROUND8(nByte);
79809 if( nByte <= p->nFree ){
79810 p->nFree -= nByte;
79813 p->nNeeded += nByte;
81528 int nByte; /* Number of bytes required for *p */
81529 nByte = ROUND8(sizeof(UnpackedRecord)) + sizeof(Mem)*(pKeyInfo->nKeyField+1);
81530 p = (UnpackedRecord *)sqlite3DbMallocRaw(pKeyInfo->db, nByte);
83642 static SQLITE_NOINLINE void *createAggContext(sqlite3_context *p, int nByte){
83645 if( nByte<=0 ){
83649 sqlite3VdbeMemClearAndResize(pMem, nByte);
83653 memset(pMem->z, 0, nByte);
83664 SQLITE_API void *sqlite3_aggregate_context(sqlite3_context *p, int nByte){
83667 testcase( nByte<0 );
83669 return createAggContext(p, nByte);
85296 int nByte;
85298 nByte =
85312 if( SQLITE_OK==sqlite3VdbeMemClearAndResize(pMem, nByte) ){
86660 i64 nByte; /* Total size of the output string or blob */
86691 nByte = pIn1->n + pIn2->n;
86692 if( nByte>db->aLimit[SQLITE_LIMIT_LENGTH] ){
86695 if( sqlite3VdbeMemGrow(pOut, (int)nByte+3, pOut==pIn2) ){
86707 pOut->z[nByte]=0;
86708 pOut->z[nByte+1] = 0;
86709 pOut->z[nByte+2] = 0;
86711 pOut->n = (int)nByte;
88048 i64 nByte; /* Data space required for this record */
88258 nByte = nHdr+nData;
88265 if( nByte+nZero<=pOut->szMalloc ){
88272 if( nByte+nZero>db->aLimit[SQLITE_LIMIT_LENGTH] ){
88275 if( sqlite3VdbeMemClearAndResize(pOut, (int)nByte) ){
88279 pOut->n = (int)nByte;
88303 assert( nByte==(int)(zPayload - (u8*)pOut->z) );
91496 int nByte; /* Bytes of runtime space required for sub-program */
91544 nByte = ROUND8(sizeof(VdbeFrame))
91548 pFrame = sqlite3DbMallocZero(db, nByte);
91555 pRt->n = nByte;
93172 int nByte; /* Size of open blob, in bytes */
93236 p->nByte = sqlite3VdbeSerialTypeLen(type);
93536 if( n<0 || iOffset<0 || ((sqlite3_int64)iOffset+n)>p->nByte ){
93611 return (p && p->pStmt) ? p->nByte : 0;
94145 int nByte, /* Bytes of data to read */
94153 p->iReadOff += nByte;
94182 if( nByte<=nAvail ){
94187 p->iReadOff += nByte;
94195 if( p->nAlloc<nByte ){
94198 while( nByte>nNew ) nNew = nNew*2;
94209 nRem = nByte - nAvail;
94223 memcpy(&p->aAlloc[nByte - nRem], aNext, nCopy);
94397 u64 nByte = 0; /* Size of PMA in bytes */
94398 rc = vdbePmaReadVarint(pReadr, &nByte);
94399 pReadr->iEof = pReadr->iReadOff + nByte;
94400 *pnByte += nByte;
94831 int nByte; /* Total bytes of space to allocate */
94837 nByte = sizeof(MergeEngine) + N * (sizeof(int) + sizeof(PmaReader));
94839 pNew = sqlite3FaultSim(100) ? 0 : (MergeEngine*)sqlite3MallocZero(nByte);
94938 static void vdbeSorterExtendFile(sqlite3 *db, sqlite3_file *pFd, i64 nByte){
94939 if( nByte<=(i64)(db->nMaxSorterMmap) && pFd->pMethods->iVersion>=3 ){
94943 sqlite3OsFileControlHint(pFd, SQLITE_FCNTL_SIZE_HINT, &nByte);
94944 sqlite3OsFetch(pFd, 0, (int)nByte, &p);
95180 int nByte;
95182 nByte = sqlite3PutVarint(aByte, iVal);
95183 vdbePmaWriteBlob(p, aByte, nByte);
100715 int nByte = dupedExprStructSize(p, flags) & 0xfff;
100717 nByte += sqlite3Strlen30NN(p->u.zToken)+1;
100719 return ROUND8(nByte);
100736 int nByte = 0;
100738 nByte = dupedExprNodeSize(p, flags);
100740 nByte += dupedExprSize(p->pLeft, flags) + dupedExprSize(p->pRight, flags);
100743 return nByte;
100866 sqlite3_int64 nByte = sizeof(*p) + sizeof(p->a[0]) * (p->nCte-1);
100867 pRet = sqlite3DbMallocZero(db, nByte);
100992 int nByte;
100995 nByte = sizeof(*p) + (p->nSrc>0 ? sizeof(p->a[0]) * (p->nSrc-1) : 0);
100996 pNew = sqlite3DbMallocRawNN(db, nByte );
108953 int nByte; /* Bytes of space required */
108970 nByte = sizeof(IndexSample) * nSample;
108971 nByte += sizeof(tRowcnt) * nIdxCol * 3 * nSample;
108972 nByte += nIdxCol * sizeof(tRowcnt); /* Space for Index.aAvgEq[] */
108974 pIdx->aSample = sqlite3DbMallocZero(db, nByte);
108986 assert( ((u8*)pSpace)-nByte==(u8*)(pIdx->aSample) );
111901 int nByte;
111904 nByte = (sizeof(char*) + sizeof(i16) + 1)*N;
111905 zExtra = sqlite3DbMallocZero(db, nByte);
113195 int nByte;
113220 nByte = sizeof(*pFKey) + (nCol-1)*sizeof(pFKey->aCol[0]) + pTo->n + 1;
113223 nByte += sqlite3Strlen30(pToCol->a[i].zEName) + 1;
113226 pFKey = sqlite3DbMallocZero(db, nByte );
113447 int nByte; /* Bytes of space for Index object + arrays */
113449 nByte = ROUND8(sizeof(Index)) + /* Index structure */
113454 p = sqlite3DbMallocZero(db, nByte + nExtra);
113463 *ppExtra = ((char*)p) + nByte;
115098 sqlite3_int64 nByte = sizeof(*pWith) + (sizeof(pWith->a[1]) * pWith->nCte);
115099 pNew = sqlite3DbRealloc(db, pWith, nByte);
117082 static void *contextMalloc(sqlite3_context *context, i64 nByte){
117085 assert( nByte>0 );
117086 testcase( nByte==db->aLimit[SQLITE_LIMIT_LENGTH] );
117087 testcase( nByte==db->aLimit[SQLITE_LIMIT_LENGTH]+1 );
117088 if( nByte>db->aLimit[SQLITE_LIMIT_LENGTH] ){
117092 z = sqlite3Malloc(nByte);
124576 u64 nByte = (wsdAutoext.nExt+1)*sizeof(wsdAutoext.aExt[0]);
124578 aNew = sqlite3_realloc64(wsdAutoext.aExt, nByte);
149845 int nByte = (pWInfo->nLevel-1-i) * sizeof(WhereLevel);
149846 memmove(&pWInfo->a[i], &pWInfo->a[i+1], nByte);
162996 u64 nByte = nUri+8; /* Bytes of space to allocate */
163002 for(iIn=0; iIn<nUri; iIn++) nByte += (zUri[iIn]=='&');
163003 zFile = sqlite3_malloc64(nByte);
164415 sqlite3_int64 nByte;
164418 nByte = strlen(zDatabase) + strlen(zJournal) + strlen(zWal) + 10;
164420 nByte += strlen(azParam[i])+1;
164422 pResult = p = sqlite3_malloc64( nByte );
164435 assert( (sqlite3_int64)(p - pResult)==nByte );
167032 int nByte;
167033 nByte = sqlite3Fts3ReadInt(*pp, &nInt);
167037 if( nByte==0 ){
167041 *pp += nByte;
167219 sqlite3_int64 nByte; /* Size of allocation used for *p */
167252 nByte = sizeof(const char *) * (argc-2);
167253 aCol = (const char **)sqlite3_malloc64(nByte);
167255 memset((void*)aCol, 0, nByte);
167256 azNotindexed = (char **)sqlite3_malloc64(nByte);
167259 memset(azNotindexed, 0, nByte);
167444 nByte = sizeof(Fts3Table) + /* Fts3Table */
167451 p = (Fts3Table*)sqlite3_malloc64(nByte);
167456 memset(p, 0, nByte);
167504 assert( zCsr <= &((char *)p)[nByte] );
168978 sqlite3_int64 nByte = (pCsr->nSegment + 16)*sizeof(Fts3SegReader*);
168979 apNew = (Fts3SegReader **)sqlite3_realloc64(pCsr->apSegment, nByte);
170758 int nByte = a[p->nToken-1].nList;
170759 char *aDoclist = sqlite3_malloc(nByte+FTS3_BUFFER_PADDING);
170761 memcpy(aDoclist, a[p->nToken-1].pList, nByte+1);
170762 memset(&aDoclist[nByte], 0, FTS3_BUFFER_PADDING);
170963 sqlite3_int64 nByte = 0;
170975 a += sqlite3Fts3GetVarintBounded(a, pEnd, &nByte);
170978 if( nDoc==0 || nByte==0 ){
170984 pCsr->nRowAvg = (int)(((nByte / nDoc) + p->nPgsz) / p->nPgsz);
172192 sqlite3_int64 nByte; /* Bytes of space to allocate here */
172223 nByte = sizeof(Fts3auxTable) + sizeof(Fts3Table) + nDb + nFts3 + 2;
172224 p = (Fts3auxTable *)sqlite3_malloc64(nByte);
172226 memset(p, 0, nByte);
172802 static void *fts3MallocZero(sqlite3_int64 nByte){
172803 void *pRet = sqlite3_malloc64(nByte);
172804 if( pRet ) memset(pRet, 0, nByte);
172878 sqlite3_int64 nByte; /* total space to allocate */
172882 nByte = sizeof(Fts3Expr) + sizeof(Fts3Phrase) + nToken;
172883 pRet = (Fts3Expr *)fts3MallocZero(nByte);
172993 int nByte = 0, iBegin = 0, iEnd = 0, iPos = 0;
172994 rc = pModule->xNext(pCursor, &zByte, &nByte, &iBegin, &iEnd, &iPos);
173001 zTemp = fts3ReallocOrFree(zTemp, nTemp + nByte);
173008 memcpy(&zTemp[nTemp], zByte, nByte);
173009 nTemp += nByte;
173011 pToken->n = nByte;
173300 int nByte = 0;
173302 rc = getNextNode(pParse, zIn, nIn, &p, &nByte);
173303 assert( nByte>0 || (rc!=SQLITE_OK && p==0) );
173390 assert( nByte>0 );
173392 assert( rc!=SQLITE_OK || (nByte>0 && nByte<=nIn) );
173393 nIn -= nByte;
173394 zIn += nByte;
175897 int nByte = 0;
175901 nByte += (int)(strlen(argv[i]) + 1);
175904 *pazDequote = azDequote = sqlite3_malloc64(sizeof(char *)*argc + nByte);
176127 int nByte = sqlite3_value_bytes(apVal[0]);
176128 pCsr->zInput = sqlite3_malloc64(nByte+1);
176132 if( nByte>0 ) memcpy(pCsr->zInput, zByte, nByte);
176133 pCsr->zInput[nByte] = 0;
176134 rc = pTab->pMod->xOpen(pTab->pTok, pCsr->zInput, nByte, &pCsr->pCsr);
177457 int nByte = sqlite3_blob_bytes(p->pSegments);
177458 *pnBlob = nByte;
177460 char *aByte = sqlite3_malloc(nByte + FTS3_NODE_PADDING);
177464 if( pnLoad && nByte>(FTS3_NODE_CHUNK_THRESHOLD) ){
177465 nByte = FTS3_NODE_CHUNKSIZE;
177466 *pnLoad = nByte;
177468 rc = sqlite3_blob_read(p->pSegments, aByte, nByte, 0);
177469 memset(&aByte[nByte], 0, FTS3_NODE_PADDING);
177517 static int fts3SegReaderRequire(Fts3SegReader *pReader, char *pFrom, int nByte){
177523 && (pFrom - pReader->aNode + nByte)>pReader->nPopulate
177995 sqlite3_int64 nByte;
177996 nByte = sizeof(Fts3SegReader) + (nElem+1)*sizeof(Fts3HashElem *);
177997 pReader = (Fts3SegReader *)sqlite3_malloc64(nByte);
178001 memset(pReader, 0, nByte);
179197 int nByte;
179226 nByte = sqlite3Fts3VarintLen(iDelta) + (isRequirePos?nList+1:0);
179227 if( nDoclist+nByte>pCsr->nBuffer ){
179229 pCsr->nBuffer = (nDoclist+nByte)*2;
179335 sqlite3_int64 nByte /* Size of new segment at iAbsLevel */
179345 i64 nLimit = (nByte*3)/2;
179792 sqlite3_int64 nByte = sizeof(u32) * ((sqlite3_int64)p->nColumn+1)*3;
179793 aSz = (u32 *)sqlite3_malloc64(nByte);
179797 memset(aSz, 0, nByte);
179859 sqlite3_int64 nByte; /* Bytes allocated at pCsr->apSegment[] */
179863 nByte = sizeof(Fts3SegReader *) * nSeg;
179864 pCsr->apSegment = (Fts3SegReader **)sqlite3_malloc64(nByte);
179869 memset(pCsr->apSegment, 0, nByte);
182155 sqlite3_int64 nByte = sizeof(u32) * (2*(sqlite3_int64)nElem + 1)
182159 pRet = sqlite3_malloc64(nByte + nStr+1);
182161 memset(pRet, 0, nByte);
182166 pRet->zMatchinfo = ((char*)pRet) + nByte;
182547 sqlite3_int64 nByte; /* Number of bytes of space to allocate */
182564 nByte = sizeof(SnippetPhrase) * nList;
182565 sIter.aPhrase = (SnippetPhrase *)sqlite3_malloc64(nByte);
182569 memset(sIter.aPhrase, 0, nByte);
187994 int nByte = (NCELL(pNode) - iCell - 1) * pRtree->nBytesPerCell;
187995 memmove(pDst, pSrc, nByte);
189617 sqlite3_int64 nByte = (pRtree->nDim+1)*(sizeof(int*)+nCell*sizeof(int));
189619 aaSorted = (int **)sqlite3_malloc64(nByte);
189625 memset(aaSorted, 0, nByte);
191846 int nByte;
191848 && (nByte = sqlite3_value_bytes(pVal))>=(4+6*sizeof(GeoCoord))
191854 && (nVertex*2*sizeof(GeoCoord) + 4)==(unsigned int)nByte
191863 memcpy(p->hdr, a, nByte);
192595 sqlite3_int64 nByte;
192604 nByte = sizeof(GeoEvent)*nVertex*2
192607 p = sqlite3_malloc64( nByte );
194275 int nByte = 0;
194300 if( nByte ){
194301 char *zNew = sqlite3_realloc(pCsr->zBuffer, nByte);
194306 pCsr->nBuffer = nByte;
194310 pCsr->zBuffer, pCsr->nBuffer, &nByte, /* Output vars */
194314 } while( nByte>pCsr->nBuffer );
194317 *pnBytes = nByte;
196018 static void *rbuMalloc(sqlite3rbu *p, sqlite3_int64 nByte){
196021 assert( nByte>0 );
196022 pRet = sqlite3_malloc64(nByte);
196026 memset(pRet, 0, nByte);
196039 sqlite3_int64 nByte = (2*sizeof(char*) + sizeof(int) + 3*sizeof(u8)) * nCol;
196042 azNew = (char**)rbuMalloc(p, nByte);
196903 sqlite3_int64 nByte = 2*(sqlite3_int64)nBind + 1;
196905 zRet = (char*)rbuMalloc(p, nByte);
198913 size_t nByte = sizeof(sqlite3rbu) + nTarget+1 + nRbu+1;
198915 p = (sqlite3rbu*)sqlite3_malloc64(nByte);
199833 sqlite3_int64 nByte = (iRegion+1) * sizeof(char*);
199834 char **apNew = (char**)sqlite3_realloc64(p->apShm, nByte);
200095 static void rbuVfsDlError(sqlite3_vfs *pVfs, int nByte, char *zErrMsg){
200097 pRealVfs->xDlError(pRealVfs, nByte, zErrMsg);
200125 static int rbuVfsRandomness(sqlite3_vfs *pVfs, int nByte, char *zBufOut){
200127 return pRealVfs->xRandomness(pRealVfs, nByte, zBufOut);
200207 size_t nByte;
200210 nByte = sizeof(rbu_vfs) + nName + 1;
200211 pNew = (rbu_vfs*)sqlite3_malloc64(nByte);
200216 memset(pNew, 0, nByte);
201910 int nByte; /* Size of serialized value in bytes */
201920 nByte = 1;
201940 nByte = 9;
201963 nByte = 1 + nVarint + n;
201968 nByte = 1;
201972 if( pnWrite ) *pnWrite += nByte;
202515 sqlite3_int64 nByte;
202549 nByte = nThis + 1;
202551 nByte += sqlite3_column_bytes(pStmt, 1);
202557 nByte += nDbCol * (sizeof(const char *) + sizeof(u8) + 1);
202558 pAlloc = sqlite3_malloc64(nByte);
202756 sqlite3_int64 nByte; /* Number of bytes to allocate */
202763 nByte = sizeof(SessionChange);
202776 rc = sessionSerializeValue(0, p, &nByte);
202781 pChange = (SessionChange *)sqlite3_malloc64(nByte);
202794 nByte = 0;
202802 sessionSerializeValue(&pChange->aRecord[nByte], p, &nByte);
202809 pChange->nRecord = nByte;
203376 static int sessionBufferGrow(SessionBuffer *p, size_t nByte, int *pRc){
203377 if( *pRc==SQLITE_OK && (size_t)(p->nAlloc-p->nBuf)<nByte ){
203382 }while( (size_t)(nNew-p->nBuf)<nByte );
203406 sqlite3_int64 nByte = 0;
203407 rc = sessionSerializeValue(0, pVal, &nByte);
203408 sessionBufferGrow(p, nByte, &rc);
203411 p->nBuf += nByte;
203558 int nByte;
203564 nByte = sqlite3_column_bytes(pStmt, iCol);
203565 if( z || (eType==SQLITE_BLOB && nByte==0) ){
203566 sessionAppendVarint(p, nByte, pRc);
203567 sessionAppendBlob(p, z, nByte, pRc);
204130 int nByte; /* Number of bytes to allocate for iterator */
204138 nByte = sizeof(sqlite3_changeset_iter);
204139 pRet = (sqlite3_changeset_iter *)sqlite3_malloc(nByte);
204218 static int sessionInputBuffer(SessionInput *pIn, int nByte){
204221 while( !pIn->bEof && (pIn->iNext+nByte)>=pIn->nData && rc==SQLITE_OK ){
204255 int nByte;
204256 aRec += sessionVarintGet((u8*)aRec, &nByte);
204257 aRec += nByte;
204342 int nByte;
204343 pIn->iNext += sessionVarintGet(aVal, &nByte);
204344 rc = sessionInputBuffer(pIn, nByte);
204346 if( nByte<0 || nByte>pIn->nData-pIn->iNext ){
204350 rc = sessionValueSetStr(apOut[i],&pIn->aData[pIn->iNext],nByte,enc);
204351 pIn->iNext += nByte;
204434 int nByte = 0;
204438 rc = sessionInputBuffer(pIn, nByte + 10);
204440 eType = pIn->aData[pIn->iNext + nByte++];
204443 nByte += sessionVarintGet(&pIn->aData[pIn->iNext+nByte], &n);
204444 nByte += n;
204445 rc = sessionInputBuffer(pIn, nByte);
204447 nByte += 8;
204451 *pnByte = nByte;
204479 int nByte;
204485 nByte = p->nCol * sizeof(sqlite3_value*) * 2 + nCopy;
204487 sessionBufferGrow(&p->tblhdr, nByte, &rc);
204855 int nByte;
204858 if( (rc = sessionChangesetBufferTblhdr(pInput, &nByte)) ){
204865 sessionAppendBlob(&sOut, &pInput->aData[pInput->iNext], nByte, &rc);
204868 pInput->iNext += nByte;
204877 int nByte;
204882 rc = sessionChangesetBufferRecord(pInput, nCol, &nByte);
204885 sessionAppendBlob(&sOut, &pInput->aData[pInput->iNext], nByte, &rc);
204886 pInput->iNext += nByte;
205798 size_t nByte = 2*pApply->nCol*sizeof(sqlite3_value*);
205804 sessionBufferGrow(&pIter2->tblhdr, nByte, &rc);
205806 if( rc==SQLITE_OK ) memset(pIter2->apValue, 0, nByte);
206201 sqlite3_int64 nByte = nRec + pExist->nRecord + sizeof(SessionChange);
206202 pNew = (SessionChange*)sqlite3_malloc64(nByte);
206211 memset(pNew, 0, nByte);
206262 sqlite3_int64 nByte;
206268 nByte = sizeof(SessionChange) + pExist->nRecord + nRec;
206269 pNew = (SessionChange *)sqlite3_malloc64(nByte);
207926 static void *sqlite3Fts5MallocZero(int *pRc, sqlite3_int64 nByte);
207999 int nByte,
210489 sqlite3_int64 nByte; /* Bytes of space to allocate */
210494 nByte = sizeof(Fts5Bm25Data) + nPhrase*2*sizeof(double);
210495 p = (Fts5Bm25Data*)sqlite3_malloc64(nByte);
210499 memset(p, 0, (size_t)nByte);
210650 static int sqlite3Fts5BufferSize(int *pRc, Fts5Buffer *pBuf, u32 nByte){
210651 if( (u32)pBuf->nSpace<nByte ){
210654 while( nNew<nByte ){
210888 static void *sqlite3Fts5MallocZero(int *pRc, sqlite3_int64 nByte){
210891 pRet = sqlite3_malloc64(nByte);
210893 if( nByte>0 ) *pRc = SQLITE_NOMEM;
210895 memset(pRet, 0, (size_t)nByte);
211280 const int nByte = sizeof(int) * FTS5_MAX_PREFIX_INDEXES;
211284 pConfig->aPrefix = sqlite3Fts5MallocZero(&rc, nByte);
211568 sqlite3_int64 nByte;
211576 nByte = nArg * (sizeof(char*) + sizeof(u8));
211577 pRet->azCol = (char**)sqlite3Fts5MallocZero(&rc, nByte);
212263 const int nByte = sizeof(Fts5ExprNode);
212264 pNew->pRoot = (Fts5ExprNode*)sqlite3Fts5MallocZero(&sParse.rc, nByte);
212394 sqlite3_int64 nByte = sizeof(Fts5PoslistReader) * nAlloc * 2;
212395 Fts5PoslistReader *aNew = (Fts5PoslistReader*)sqlite3_malloc64(nByte);
212475 sqlite3_int64 nByte = sizeof(Fts5PoslistReader) * pPhrase->nTerm;
212476 aIter = (Fts5PoslistReader*)sqlite3_malloc64(nByte);
212610 sqlite3_int64 nByte = sizeof(Fts5NearTrimmer) * pNear->nPhrase;
212611 a = (Fts5NearTrimmer*)sqlite3Fts5MallocZero(&rc, nByte);
213519 sqlite3_int64 nByte;
213520 nByte = sizeof(Fts5ExprNearset) + SZALLOC * sizeof(Fts5ExprPhrase*);
213521 pRet = sqlite3_malloc64(nByte);
213525 memset(pRet, 0, (size_t)nByte);
213529 sqlite3_int64 nByte;
213531 nByte = sizeof(Fts5ExprNearset) + nNew * sizeof(Fts5ExprPhrase*);
213532 pRet = (Fts5ExprNearset*)sqlite3_realloc64(pNear, nByte);
213596 sqlite3_int64 nByte = sizeof(Fts5ExprTerm) + sizeof(Fts5Buffer) + nToken+1;
213597 pSyn = (Fts5ExprTerm*)sqlite3_malloc64(nByte);
213601 memset(pSyn, 0, (size_t)nByte);
213699 sqlite3_int64 nByte = sizeof(Fts5ExprPhrase*) * (pParse->nPhrase + 8);
213701 apNew = (Fts5ExprPhrase**)sqlite3_realloc64(pParse->apPhrase, nByte);
213756 sqlite3_int64 nByte;
213758 nByte = sizeof(Fts5Colset) + (pColsetOrig->nCol-1) * sizeof(int);
213759 pColset = (Fts5Colset*)sqlite3Fts5MallocZero(&rc, nByte);
213761 memcpy(pColset, pColsetOrig, (size_t)nByte);
213975 sqlite3_int64 nByte = sizeof(Fts5Colset) + (pOrig->nCol-1) * sizeof(int);
213976 pRet = (Fts5Colset*)sqlite3Fts5MallocZero(pRc, nByte);
213978 memcpy(pRet, pOrig, (size_t)nByte);
214105 int nByte = sizeof(Fts5ExprNode*) * pSub->nChild;
214106 memcpy(&p->apChild[p->nChild], pSub->apChild, nByte);
214129 sqlite3_int64 nByte; /* Bytes of space to allocate for this node */
214146 nByte = sizeof(Fts5ExprNode) + sizeof(Fts5ExprNode*)*(nChild-1);
214147 pRet = (Fts5ExprNode*)sqlite3Fts5MallocZero(&pParse->rc, nByte);
214261 sqlite3_int64 nByte = 0;
214267 nByte += (int)strlen(pTerm->zTerm) * 2 + 3 + 2;
214269 zQuoted = sqlite3_malloc64(nByte);
214984 sqlite3_int64 nByte;
214990 nByte = sizeof(Fts5HashEntry*) * pNew->nSlot;
214991 pNew->aSlot = (Fts5HashEntry**)sqlite3_malloc64(nByte);
214997 memset(pNew->aSlot, 0, (size_t)nByte);
215106 int nByte = sqlite3Fts5GetVarintLen((u32)nPos);
215107 memmove(&pPtr[p->iSzPoslist + nByte], &pPtr[p->iSzPoslist + 1], nSz);
215109 nData += (nByte-1);
215164 sqlite3_int64 nByte = sizeof(Fts5HashEntry) + (nToken+1) + 1 + 64;
215165 if( nByte<128 ) nByte = 128;
215175 p = (Fts5HashEntry*)sqlite3_malloc64(nByte);
215178 p->nAlloc = (int)nByte;
216022 static void *fts5IdxMalloc(Fts5Index *p, sqlite3_int64 nByte){
216023 return sqlite3Fts5MallocZero(&p->rc, nByte);
216121 int nByte = sqlite3_blob_bytes(p->pReader);
216122 sqlite3_int64 nAlloc = sizeof(Fts5Data) + nByte + FTS5_DATA_PADDING;
216125 pRet->nn = nByte;
216132 rc = sqlite3_blob_read(p->pReader, aOut, nByte, 0);
216139 pRet->p[nByte] = 0x00;
216140 pRet->p[nByte+1] = 0x00;
216299 sqlite3_int64 nByte; /* Bytes of space to allocate at pRet */
216315 nByte = (
216319 pRet = (Fts5Structure*)sqlite3Fts5MallocZero(&rc, nByte);
216383 sqlite3_int64 nByte = (
216388 pStruct = sqlite3_realloc64(pStruct, nByte);
216413 sqlite3_int64 nByte;
216415 nByte = (pLvl->nSeg + nExtra) * sizeof(Fts5StructureSegment);
216416 aNew = sqlite3_realloc64(pLvl->aSeg, nByte);
216930 sqlite3_int64 nByte = sizeof(Fts5DlidxIter) + i * sizeof(Fts5DlidxLvl);
216933 pNew = (Fts5DlidxIter*)sqlite3_realloc64(pIter, nByte);
219142 size_t nByte = sizeof(Fts5DlidxWriter) * (nLvl - pWriter->nDlidx);
219143 memset(&aDlidx[pWriter->nDlidx], 0, nByte);
220115 sqlite3_int64 nByte = sizeof(Fts5Structure);
220139 nByte += (pStruct->nLevel+1) * sizeof(Fts5StructureLevel);
220140 pNew = (Fts5Structure*)sqlite3Fts5MallocZero(&p->rc, nByte);
220144 nByte = nSeg * sizeof(Fts5StructureSegment);
220149 pLvl->aSeg = (Fts5StructureSegment*)sqlite3Fts5MallocZero(&p->rc, nByte);
220245 int nByte = nData + 9 + 9 + FTS5_DATA_ZERO_PADDING;
220247 if( p->rc==SQLITE_OK && 0==fts5BufferGrow(&p->rc, pBuf, nByte) ){
220765 int nByte,
220771 if( n>=nByte ) return 0; /* Input contains fewer than nChar chars */
220773 if( n>=nByte ) return 0;
220776 if( n>=nByte ){
220832 int nByte = sqlite3Fts5IndexCharlenToBytelen(pToken, nToken, nChar);
220833 if( nByte ){
220836 nByte
221339 int nByte;
221340 iOff += fts5GetVarint32(&pLeaf->p[iOff], nByte);
221341 if( (iOff+nByte)>pLeaf->szLeaf ){
221344 fts5BufferSet(&p->rc, &buf1, nByte, &pLeaf->p[iOff]);
221347 int nKeep, nByte;
221349 iOff += fts5GetVarint32(&pLeaf->p[iOff], nByte);
221350 if( nKeep>buf1.n || (iOff+nByte)>pLeaf->szLeaf ){
221354 fts5BufferAppendBlob(&p->rc, &buf1, nByte, &pLeaf->p[iOff]);
221959 int nByte; /* Bytes of data */
221962 iPgidxOff += fts5GetVarint32(&a[iPgidxOff], nByte);
221963 iPgidxPrev += nByte;
221967 fts5GetVarint32(&a[iPgidxOff], nByte);
221968 iEnd = iPgidxPrev + nByte;
221978 iOff += fts5GetVarint32(&a[iOff], nByte);
221979 if( nByte>term.n ){
221983 term.n = nByte;
221985 iOff += fts5GetVarint32(&a[iOff], nByte);
221986 if( iOff+nByte>n ){
221990 fts5BufferAppendBlob(&rc, &term, nByte, &a[iOff]);
221991 iOff += nByte;
222754 sqlite3_int64 nByte; /* Bytes of space to allocate */
222759 nByte = sizeof(Fts5Cursor) + pConfig->nCol * sizeof(int);
222760 pCsr = (Fts5Cursor*)sqlite3_malloc64(nByte);
222763 memset(pCsr, 0, (size_t)nByte);
223045 sqlite3_int64 nByte;
223051 nByte = sizeof(Fts5Sorter) + sizeof(int) * (nPhrase-1);
223052 pSorter = (Fts5Sorter*)sqlite3_malloc64(nByte);
223054 memset(pSorter, 0, (size_t)nByte);
223171 sqlite3_int64 nByte;
223173 nByte = sizeof(sqlite3_value*)*pCsr->nRankArg;
223174 pCsr->apRankArg = (sqlite3_value**)sqlite3Fts5MallocZero(&rc, nByte);
223960 sqlite3_int64 nByte = sizeof(Fts5PoslistReader) * nIter;
223961 pCsr->aInstIter = (Fts5PoslistReader*)sqlite3Fts5MallocZero(&rc, nByte);
224463 int nByte = sqlite3Fts5ExprPoslist(pCsr->pExpr, i, &dummy);
224464 sqlite3Fts5BufferAppendVarint(&rc, &val, nByte);
224481 int nByte;
224482 rc = sqlite3Fts5ExprPhraseCollist(pCsr->pExpr, i, &dummy, &nByte);
224483 sqlite3Fts5BufferAppendVarint(&rc, &val, nByte);
224648 sqlite3_int64 nByte; /* Bytes of space to allocate */
224651 nByte = sizeof(Fts5Auxiliary) + nName;
224652 pAux = (Fts5Auxiliary*)sqlite3_malloc64(nByte);
224654 memset(pAux, 0, (size_t)nByte);
224685 sqlite3_int64 nByte; /* Bytes of space to allocate */
224689 nByte = sizeof(Fts5TokenizerModule) + nName;
224690 pNew = (Fts5TokenizerModule*)sqlite3_malloc64(nByte);
224692 memset(pNew, 0, (size_t)nByte);
225245 sqlite3_int64 nByte; /* Bytes of space to allocate */
225247 nByte = sizeof(Fts5Storage) /* Fts5Storage object */
225249 *pp = p = (Fts5Storage*)sqlite3_malloc64(nByte);
225252 memset(p, 0, (size_t)nByte);
225815 int nByte = sqlite3Fts5IndexCharlenToBytelen(pToken, nToken, nChar);
225816 if( nByte ){
225817 rc = sqlite3Fts5TermsetAdd(pTermset, ii+1, pToken, nByte, &bPresent);
225820 pCtx->iRowid, iCol, iPos, ii+1, pToken, nByte
226212 static void asciiFold(char *aOut, const char *aIn, int nByte){
226214 for(i=0; i<nByte; i++){
226244 int nByte;
226259 nByte = ie-is;
226260 if( nByte>nFold ){
226262 pFold = sqlite3_malloc64((sqlite3_int64)nByte*2);
226267 nFold = nByte*2;
226269 asciiFold(pFold, &pText[is], nByte);
226272 rc = xToken(pCtx, 0, pFold, nByte, is, ie);
228709 int nByte; /* Bytes of space to allocate */
228723 nByte = sizeof(Fts5VocabTable) + nDb + nTab;
228724 pRet = sqlite3Fts5MallocZero(&rc, nByte);
228893 int nByte = pFts5->pConfig->nCol * sizeof(i64)*2 + sizeof(Fts5VocabCursor);
228894 pCsr = (Fts5VocabCursor*)sqlite3Fts5MallocZero(&rc, nByte);