Lines Matching refs:pVFile
120 VFile *pVFile; /* The underlying file */ member
1342 VFile *pVFile = p->pVFile; in inmemClose() local
1343 pVFile->nRef--; in inmemClose()
1344 if( pVFile->nRef==0 && pVFile->zFilename==0 ){ in inmemClose()
1345 pVFile->sz = -1; in inmemClose()
1346 free(pVFile->a); in inmemClose()
1347 pVFile->a = 0; in inmemClose()
1358 VFile *pVFile = pHandle->pVFile; in inmemRead() local
1359 if( iOfst<0 || iOfst>=pVFile->sz ){ in inmemRead()
1363 if( iOfst+iAmt>pVFile->sz ){ in inmemRead()
1365 iAmt = (int)(pVFile->sz - iOfst); in inmemRead()
1366 memcpy(pData, pVFile->a + iOfst, iAmt); in inmemRead()
1369 memcpy(pData, pVFile->a + iOfst, iAmt); in inmemRead()
1379 VFile *pVFile = pHandle->pVFile; in inmemWrite() local
1380 if( iOfst+iAmt > pVFile->sz ){ in inmemWrite()
1384 pVFile->a = safe_realloc(pVFile->a, (int)(iOfst+iAmt)); in inmemWrite()
1385 if( iOfst > pVFile->sz ){ in inmemWrite()
1386 memset(pVFile->a + pVFile->sz, 0, (int)(iOfst - pVFile->sz)); in inmemWrite()
1388 pVFile->sz = (int)(iOfst + iAmt); in inmemWrite()
1390 memcpy(pVFile->a + iOfst, pData, iAmt); in inmemWrite()
1395 VFile *pVFile = pHandle->pVFile; in inmemTruncate() local
1396 if( pVFile->sz>iSize && iSize>=0 ) pVFile->sz = (int)iSize; in inmemTruncate()
1403 *pSize = ((VHandle*)pFile)->pVFile->sz; in inmemFileSize()
1465 VFile *pVFile = createVFile(zFilename, 0, (unsigned char*)""); in inmemOpen() local
1467 if( pVFile==0 ){ in inmemOpen()
1470 pHandle->pVFile = pVFile; in inmemOpen()
1471 pVFile->nRef++; in inmemOpen()
1485 VFile *pVFile = findVFile(zFilename); in inmemDelete() local
1486 if( pVFile==0 ) return SQLITE_OK; in inmemDelete()
1487 if( pVFile->nRef==0 ){ in inmemDelete()
1488 free(pVFile->zFilename); in inmemDelete()
1489 pVFile->zFilename = 0; in inmemDelete()
1490 pVFile->sz = -1; in inmemDelete()
1491 free(pVFile->a); in inmemDelete()
1492 pVFile->a = 0; in inmemDelete()
1506 VFile *pVFile = findVFile(zFilename); in inmemAccess() local
1507 *pResOut = pVFile!=0; in inmemAccess()