• Home
  • History
  • Annotate
  • Raw
  • Download
  • only in /netgear-WNDR4500-V1.0.1.40_1.0.68/ap/gpl/minidlna/sqlite-3.6.22/

Lines Matching defs:nByte

1335   void (*xDlError)(sqlite3_vfs*, int nByte, char *zErrMsg);
1338 int (*xRandomness)(sqlite3_vfs*, int nByte, char *zOut);
1778 #define SQLITE_CONFIG_HEAP 8 /* void*, int nByte, int min */
2889 ** ^If the nByte argument is less than zero, then zSql is read up to the
2890 ** first zero terminator. ^If nByte is non-negative, then it is the maximum
2891 ** number of bytes read from zSql. ^When nByte is non-negative, the
2893 ** the nByte-th byte, whichever comes first. If the caller knows
2895 ** performance advantage to be gained by passing an nByte parameter that
2956 int nByte, /* Maximum length of zSql in bytes. */
2963 int nByte, /* Maximum length of zSql in bytes. */
2970 int nByte, /* Maximum length of zSql in bytes. */
2977 int nByte, /* Maximum length of zSql in bytes. */
8952 u8 nByte; /* Size in byte of text or blob. */
10295 SQLITE_PRIVATE int sqlite3Utf8CharLen(const char *pData, int nByte);
12173 SQLITE_PRIVATE void sqlite3OsDlError(sqlite3_vfs *pVfs, int nByte, char *zBufOut){
12174 pVfs->xDlError(pVfs, nByte, zBufOut);
12183 SQLITE_PRIVATE int sqlite3OsRandomness(sqlite3_vfs *pVfs, int nByte, char *zBufOut){
12184 return pVfs->xRandomness(pVfs, nByte, zBufOut);
12444 static void *sqlite3MemMalloc(int nByte){ return 0; }
12446 static void *sqlite3MemRealloc(void *pPrior, int nByte){ return 0; }
12507 ** For this low-level routine, we are guaranteed that nByte>0 because
12508 ** cases of nByte<=0 will be intercepted and dealt with by higher level
12511 static void *sqlite3MemMalloc(int nByte){
12513 assert( nByte>0 );
12514 nByte = ROUND8(nByte);
12515 p = malloc( nByte+8 );
12517 p[0] = nByte;
12544 ** redirected to xMalloc. Similarly, we know that nByte>0 becauses
12545 ** cases where nByte<=0 will have been intercepted by higher-level
12548 static void *sqlite3MemRealloc(void *pPrior, int nByte){
12550 assert( pPrior!=0 && nByte>0 );
12551 nByte = ROUND8(nByte);
12554 p = realloc(p, nByte+8 );
12556 p[0] = nByte;
12836 static void randomFill(char *pBuf, int nByte){
12839 y = nByte | 1;
12840 while( nByte >= 4 ){
12846 nByte -= 4;
12848 while( nByte-- > 0 ){
12857 ** Allocate nByte bytes of memory.
12859 static void *sqlite3MemMalloc(int nByte){
12869 nReserve = ROUND8(nByte);
12894 mem.xBacktrace(nByte, pHdr->nBacktrace-1, &aAddr[1]);
12902 pHdr->iSize = nByte;
12903 adjustStats(nByte, +1);
12906 randomFill((char*)pInt, nByte);
12907 memset(((char*)pInt)+nByte, 0x65, nReserve-nByte);
12958 static void *sqlite3MemRealloc(void *pPrior, int nByte){
12963 pNew = sqlite3MemMalloc(nByte);
12965 memcpy(pNew, pPrior, nByte<pOldHdr->iSize ? nByte : pOldHdr->iSize);
12966 if( nByte>pOldHdr->iSize ){
12967 randomFill(&((char*)pNew)[pOldHdr->iSize], nByte - pOldHdr->iSize);
13323 static void memsys3OutOfMemory(int nByte){
13328 sqlite3_release_memory(nByte);
13442 static void *memsys3MallocUnsafe(int nByte){
13449 if( nByte<=12 ){
13452 nBlock = (nByte + 11)/8;
14012 ** The caller guarantees that nByte positive.
14018 static void *memsys5MallocUnsafe(int nByte){
14024 /* nByte must be a positive */
14025 assert( nByte>0 );
14029 if( (u32)nByte>mem5.maxRequest ){
14030 mem5.maxRequest = nByte;
14036 if( nByte > 0x40000000 ){
14040 /* Round nByte up to the next valid power of two */
14041 for(iFullSz=mem5.szAtom, iLogsize=0; iFullSz<nByte; iFullSz *= 2, iLogsize++){}
14063 mem5.totalExcess += iFullSz - nByte;
14230 int nByte; /* Number of bytes of memory available to this allocator */
14245 nByte = sqlite3GlobalConfig.nHeap;
14255 mem5.nBlock = (nByte / (mem5.szAtom+sizeof(u8)));
15792 static void sqlite3MallocAlarm(int nByte){
15802 xCallback(pArg, nowUsed, nByte);
18206 ** pZ is a UTF-8 encoded unicode string. If nByte is less than zero,
18208 ** the first 0x00 byte. If nByte is not less than zero, return the
18209 ** number of unicode characters in the first nByte of pZ (or up to
18212 SQLITE_PRIVATE int sqlite3Utf8CharLen(const char *zIn, int nByte){
18216 if( nByte>=0 ){
18217 zTerm = &z[nByte];
18266 SQLITE_PRIVATE char *sqlite3Utf16to8(sqlite3 *db, const void *z, int nByte){
18270 sqlite3VdbeMemSetStr(&m, z, nByte, SQLITE_UTF16NATIVE, SQLITE_STATIC);
20302 static int os2Truncate( sqlite3_file *id, i64 nByte ){
20305 OSTRACE3( "TRUNCATE %d %lld\n", pFile->h, nByte );
20307 rc = DosSetFileSize( pFile->h, nByte );
24586 static int unixTruncate(sqlite3_file *id, i64 nByte){
24590 rc = ftruncate(((unixFile*)id)->h, (off_t)nByte);
24603 if( ((unixFile*)id)->inNormalWrite && nByte==0 ){
27295 int nByte;
27298 nByte = WideCharToMultiByte(CP_UTF8, 0, zWideFilename, -1, 0, 0, 0, 0);
27299 zFilename = malloc( nByte );
27303 nByte = WideCharToMultiByte(CP_UTF8, 0, zWideFilename, -1, zFilename, nByte,
27305 if( nByte == 0 ){
27320 int nByte;
27324 nByte = MultiByteToWideChar(codepage, 0, zFilename, -1, NULL,0)*sizeof(WCHAR);
27325 zMbcsFilename = malloc( nByte*sizeof(zMbcsFilename[0]) );
27329 nByte = MultiByteToWideChar(codepage, 0, zFilename, -1, zMbcsFilename, nByte);
27330 if( nByte==0 ){
27345 int nByte;
27349 nByte = WideCharToMultiByte(codepage, 0, zWideFilename, -1, 0, 0, 0, 0);
27350 zFilename = malloc( nByte );
27354 nByte = WideCharToMultiByte(codepage, 0, zWideFilename, -1, zFilename, nByte,
27356 if( nByte == 0 ){
27849 static int winTruncate(sqlite3_file *id, sqlite3_int64 nByte){
27850 LONG upperBits = (LONG)((nByte>>32) & 0x7fffffff);
27851 LONG lowerBits = (LONG)(nByte & 0xffffffff);
27857 OSTRACE3("TRUNCATE %d %lld\n", pFile->h, nByte);
27864 /* SetEndOfFile will fail if nByte is negative */
28683 int nByte;
28690 nByte = GetFullPathNameW((WCHAR*)zConverted, 0, 0, 0) + 3;
28691 zTemp = malloc( nByte*sizeof(zTemp[0]) );
28696 GetFullPathNameW((WCHAR*)zConverted, nByte, zTemp, 0);
28707 nByte = GetFullPathNameA((char*)zConverted, 0, 0, 0) + 3;
28708 zTemp = malloc( nByte*sizeof(zTemp[0]) );
28713 GetFullPathNameA((char*)zConverted, nByte, zTemp, 0);
29657 int nByte;
29658 nByte = pCache->szPage + pCache->szExtra + sizeof(PgHdr);
29659 p = sqlite3GlobalConfig.pcache.xCreate(nByte, pCache->bPurgeable);
30168 static void *pcache1Alloc(int nByte){
30171 if( nByte<=pcache1.szSlot && pcache1.pFree ){
30175 sqlite3StatusSet(SQLITE_STATUS_PAGECACHE_SIZE, nByte);
30186 p = sqlite3Malloc(nByte);
30219 int nByte = sizeof(PgHdr1) + pCache->szPage;
30220 void *pPg = pcache1Alloc(nByte);
31762 static u32 pager_datahash(int nByte, unsigned char *pData){
31765 for(i=0; i<nByte; i++){
38688 ** Allocate nByte bytes of space from within the B-Tree page passed
38700 static int allocateSpace(MemPage *pPage, int nByte, int *pIdx){
38712 assert( nByte>=0 ); /* Minimum cell size is 4 */
38713 assert( pPage->nFree>=nByte );
38716 assert( nByte < usableSize-8 );
38744 if( size>=nByte ){
38745 int x = size - nByte;
38769 testcase( gap+2+nByte==top );
38770 if( gap+2+nByte>top ){
38774 assert( gap+nByte<=top );
38784 top -= nByte;
38786 assert( top+nByte <= pPage->pBt->usableSize );
41181 ** If argument eOp is false, then nByte bytes of data are copied
41183 ** then sqlite3PagerWrite() is called on pDbPage and nByte bytes
41191 int nByte, /* Number of bytes to copy */
41201 memcpy(pPayload, pBuf, nByte);
41204 memcpy(pBuf, pPayload, nByte);
46189 int nByte;
46194 /* Set nByte to the number of bytes required to store the expanded blob. */
46195 nByte = pMem->n + pMem->u.nZero;
46196 if( nByte<=0 ){
46197 nByte = 1;
46199 if( sqlite3VdbeMemGrow(pMem, nByte, 1) ){
46245 const int nByte = 32;
46255 if( sqlite3VdbeMemGrow(pMem, nByte, 0) ){
46266 sqlite3_snprintf(nByte, pMem->z, "%lld", pMem->u.i);
46269 sqlite3_snprintf(nByte, pMem->z, "%!.15g", pMem->r);
46711 int nByte = n; /* New value for pMem->n */
46730 if( nByte<0 ){
46733 for(nByte=0; nByte<=iLimit && z[nByte]; nByte++){}
46735 for(nByte=0; nByte<=iLimit && (z[nByte] | z[nByte+1]); nByte+=2){}
46745 int nAlloc = nByte;
46749 if( nByte>iLimit ){
46767 pMem->n = nByte;
46778 if( nByte>iLimit ){
47453 int nByte = (p->nSub+1)*sizeof(SubProgram*);
47459 p->apSub = sqlite3DbReallocOrFree(v->db, p->apSub, nByte);
47875 int nField, nByte;
47878 nByte = sizeof(*pKeyInfo) + (nField-1)*sizeof(pKeyInfo->aColl[0]) + nField;
47879 pKeyInfo = sqlite3Malloc( nByte );
47883 memcpy(pKeyInfo, zP4, nByte);
48295 int nByte = (nSub+1)*sizeof(SubProgram*);
48300 if( j==nSub && SQLITE_OK==sqlite3VdbeMemGrow(pSub, nByte, 1) ){
48435 ** nByte is the number of bytes of space needed.
48447 int nByte, /* Number of bytes to allocate */
48454 nByte = ROUND8(nByte);
48455 if( &(*ppFrom)[nByte] <= pEnd ){
48457 *ppFrom += nByte;
48459 *pnByte += nByte;
48522 int nByte; /* How much extra memory needed */
48544 nByte = 0;
48545 p->aMem = allocSpace(p->aMem, nMem*sizeof(Mem), &zCsr, zEnd, &nByte);
48546 p->aVar = allocSpace(p->aVar, nVar*sizeof(Mem), &zCsr, zEnd, &nByte);
48547 p->apArg = allocSpace(p->apArg, nArg*sizeof(Mem*), &zCsr, zEnd, &nByte);
48548 p->azVar = allocSpace(p->azVar, nVar*sizeof(char*), &zCsr, zEnd, &nByte);
48550 &zCsr, zEnd, &nByte);
48551 if( nByte ){
48552 p->pFree = sqlite3DbMallocZero(db, nByte);
48555 zEnd = &zCsr[nByte];
48556 }while( nByte && !db->mallocFailed );
49860 int nByte; /* Memory space needed to hold p, in bytes */
49876 nByte = ROUND8(sizeof(UnpackedRecord)) + sizeof(Mem)*(pKeyInfo->nField+1);
49877 if( nByte>szSpace ){
49878 p = sqlite3DbMallocRaw(pKeyInfo->db, nByte);
50737 SQLITE_API void *sqlite3_aggregate_context(sqlite3_context *p, int nByte){
50742 testcase( nByte<0 );
50744 if( nByte<=0 ){
50749 sqlite3VdbeMemGrow(pMem, nByte, 0);
50753 memset(pMem->z, 0, nByte);
51830 int nByte;
51832 nByte =
51842 if( SQLITE_OK==sqlite3VdbeMemGrow(pMem, nByte, 0) ){
52307 i64 nByte;
52381 i64 nByte; /* Data space required for this record */
52589 int nByte; /* Bytes of runtime space required for sub-program */
53284 i64 nByte;
53298 u.ae.nByte = pIn1->n + pIn2->n;
53299 if( u.ae.nByte>db->aLimit[SQLITE_LIMIT_LENGTH] ){
53303 if( sqlite3VdbeMemGrow(pOut, (int)u.ae.nByte+2, pOut==pIn2) ){
53310 pOut->z[u.ae.nByte] = 0;
53311 pOut->z[u.ae.nByte+1] = 0;
53313 pOut->n = (int)u.ae.nByte;
54512 i64 nByte; /* Data space required for this record */
54542 u.ao.nByte = 0; /* Data space required for this record */
54580 u.ao.nByte = u.ao.nHdr+u.ao.nData-u.ao.nZero;
54581 if( u.ao.nByte>db->aLimit[SQLITE_LIMIT_LENGTH] ){
54592 if( sqlite3VdbeMemGrow(pOut, (int)u.ao.nByte, 0) ){
54604 u.ao.i += sqlite3VdbeSerialPut(&u.ao.zNewRecord[u.ao.i], (int)(u.ao.nByte-u.ao.i), u.ao.pRec,u.ao.file_format);
54606 assert( u.ao.i==u.ao.nByte );
54609 pOut->n = (int)u.ao.nByte;
57043 int nByte; /* Bytes of runtime space required for sub-program */
57090 u.by.nByte = ROUND8(sizeof(VdbeFrame))
57093 u.by.pFrame = sqlite3DbMallocZero(db, u.by.nByte);
58043 int nByte; /* Size of open blob, in bytes */
58290 pBlob->nByte = sqlite3VdbeSerialTypeLen(type);
58353 if( n<0 || iOffset<0 || (iOffset+n)>p->nByte ){
58400 ** The Incrblob.nByte field is fixed for the lifetime of the Incrblob
58405 return p ? p->nByte : 0;
60934 int nByte = dupedExprStructSize(p, flags) & 0xfff;
60936 nByte += sqlite3Strlen30(p->u.zToken)+1;
60938 return ROUND8(nByte);
60955 int nByte = 0;
60957 nByte = dupedExprNodeSize(p, flags);
60959 nByte += dupedExprSize(p->pLeft, flags) + dupedExprSize(p->pRight, flags);
60962 return nByte;
61116 int nByte;
61118 nByte = sizeof(*p) + (p->nSrc>0 ? sizeof(p->a[0]) * (p->nSrc-1) : 0);
61119 pNew = sqlite3DbMallocRaw(db, nByte );
65395 pSample->nByte = (u8)n;
68367 int nByte;
68392 nByte = sizeof(*pFKey) + (nCol-1)*sizeof(pFKey->aCol[0]) + pTo->n + 1;
68395 nByte += sqlite3Strlen30(pToCol->a[i].zName) + 1;
68398 pFKey = sqlite3DbMallocZero(db, nByte );
71290 ** Allocate nByte bytes of space using sqlite3_malloc(). If the
71293 ** If nByte is larger than the maximum string or blob length, then
71296 static void *contextMalloc(sqlite3_context *context, i64 nByte){
71299 assert( nByte>0 );
71300 testcase( nByte==db->aLimit[SQLITE_LIMIT_LENGTH] );
71301 testcase( nByte==db->aLimit[SQLITE_LIMIT_LENGTH]+1 );
71302 if( nByte>db->aLimit[SQLITE_LIMIT_LENGTH] ){
71306 z = sqlite3Malloc((int)nByte);
76603 int nByte = (wsdAutoext.nExt+1)*sizeof(wsdAutoext.aExt[0]);
76605 aNew = sqlite3_realloc(wsdAutoext.aExt, nByte);
88511 db, pColl->enc, aSample[i].u.z, aSample[i].nByte, &nSample
88522 r = pColl->xCmp(pColl->pUser, aSample[i].nByte, aSample[i].u.z, n, z);
99009 int nByte; /* Size of allocation used for *p */
99046 nByte = sizeof(Fts3Table) + /* Fts3Table */
99051 p = (Fts3Table*)sqlite3_malloc(nByte);
99056 memset(p, 0, nByte);
99089 assert( zCsr <= &((char *)p)[nByte] );
101041 int nByte; /* total space to allocate */
101047 nByte = sizeof(Fts3Expr) + sizeof(Fts3Phrase) + nToken;
101048 pRet = (Fts3Expr *)sqlite3_malloc(nByte);
101052 memset(pRet, 0, nByte);
101127 int nByte = sizeof(Fts3Expr) + sizeof(Fts3Phrase);
101128 p = fts3ReallocOrFree(p, nByte+ii*sizeof(struct PhraseToken));
101134 memset(p, 0, nByte);
101158 int nByte = sizeof(Fts3Expr) + sizeof(Fts3Phrase);
101159 nByte += (p?(p->pPhrase->nToken-1):0) * sizeof(struct PhraseToken);
101160 p = fts3ReallocOrFree(p, nByte + nTemp);
101165 zNew = &(((char *)p)[nByte]);
101168 memset(p, 0, nByte+nTemp);
101448 int nByte = 0;
101449 rc = getNextNode(pParse, zIn, nIn, &p, &nByte);
101534 assert( nByte>0 );
101536 assert( rc!=SQLITE_OK || (nByte>0 && nByte<=nIn) );
101537 nIn -= nByte;
101538 zIn += nByte;
104606 int nByte = sizeof(Fts3SegReader) + (nElem+1)*sizeof(Fts3HashElem *);
104607 pReader = (Fts3SegReader *)sqlite3_malloc(nByte);
104611 memset(pReader, 0, nByte);
105549 int nByte;
105566 nByte = sqlite3Fts3VarintLen(iDocid-iPrev) + (isRequirePos?nList+1:0);
105567 if( nDoclist+nByte>nAlloc ){
105569 nAlloc = nDoclist+nByte*2;
105928 short int nByte; /* Number of bytes in the term */
106036 int iStart, int nByte /* Offset and size of the match */
106058 pMatch->nByte = (short)nByte;
106413 pMatch->iCol, pMatch->iTerm, pMatch->iStart, pMatch->nByte);
106447 while( i<nMatch && aMatch[i].iStart+aMatch[i].nByte<iBreak ){ i++; }
106452 if( i>0 && aMatch[i-1].iStart+aMatch[i-1].nByte>=iBreak ){
106543 iEnd = aMatch[i].iStart + aMatch[i].nByte + 40;
106562 fts3SnippetAppend(&sb, &zDoc[iStart], aMatch[iMatch].nByte);
106564 iStart += aMatch[iMatch].nByte;
107709 int nByte = (NCELL(pNode) - iCell - 1) * pRtree->nBytesPerCell;
107710 memmove(pDst, pSrc, nByte);
108995 int nByte = (pRtree->nDim+1)*(sizeof(int*)+nCell*sizeof(int));
108997 aaSorted = (int **)sqlite3_malloc(nByte);
109003 memset(aaSorted, 0, nByte);
110786 int nByte = 0;
110811 if( nByte ){
110812 char *zNew = sqlite3_realloc(pCsr->zBuffer, nByte);
110817 pCsr->nBuffer = nByte;
110821 pCsr->zBuffer, pCsr->nBuffer, &nByte, /* Output vars */
110825 } while( nByte>pCsr->nBuffer );
110828 *pnBytes = nByte;