Fix some test code so that testfixture can build with SQLITE_OMIT_WAL defined.
FossilOrigin-Name: dd009cd7aec3598e930806907601f4f0f9b0021ea99fa6c5e29e88f1246066ed
This commit is contained in:
parent
7d14ffe4e1
commit
7093a3be03
18
manifest
18
manifest
@ -1,5 +1,5 @@
|
||||
C Additional\scorner-case\sfixes\sfor\sthe\sin-scan-vs-index\sor\sOP_SeekScan\noptimization.
|
||||
D 2020-10-02T13:48:57.472
|
||||
C Fix\ssome\stest\scode\sso\sthat\stestfixture\scan\sbuild\swith\sSQLITE_OMIT_WAL\sdefined.
|
||||
D 2020-10-02T15:15:18.200
|
||||
F .fossil-settings/empty-dirs dbb81e8fc0401ac46a1491ab34a7f2c7c0452f2f06b54ebb845d024ca8283ef1
|
||||
F .fossil-settings/ignore-glob 35175cdfcf539b2318cb04a9901442804be81cd677d8b889fcc9149c21f239ea
|
||||
F LICENSE.md df5091916dbb40e6e9686186587125e1b2ff51f022cc334e886c19a0e9982724
|
||||
@ -552,7 +552,7 @@ F src/test2.c 3efb99ab7f1fc8d154933e02ae1378bac9637da5
|
||||
F src/test3.c 61798bb0d38b915067a8c8e03f5a534b431181f802659a6616f9b4ff7d872644
|
||||
F src/test4.c 7c4420e01c577b5c4add2cb03119743b1a357543d347773b9e717195ea967159
|
||||
F src/test5.c 328aae2c010c57a9829d255dc099d6899311672d
|
||||
F src/test6.c e8d839fbc552ce044bec8234561a2d5b8819b48e29548ad0ba400471697946a8
|
||||
F src/test6.c ae73a3a42bbc982fb9e301b84d30bda65a307be48c6dff20aba1461e17a9b0ce
|
||||
F src/test7.c 5612e9aecf934d6df7bba6ce861fdf5ba5456010
|
||||
F src/test8.c 7fb971777c2c79c734bb52757191d68d4af659b8de9b4a071be3f527a9d19a02
|
||||
F src/test9.c 12e5ba554d2d1cbe0158f6ab3f7ffcd7a86ee4e5
|
||||
@ -565,7 +565,7 @@ F src/test_btree.c 8b2dc8b8848cf3a4db93f11578f075e82252a274
|
||||
F src/test_config.c 5ea19bf0972a9d91728518b4d30e91477acce80496003ecbef3a7fb18d0bd081
|
||||
F src/test_delete.c e2fe07646dff6300b48d49b2fee2fe192ed389e834dd635e3b3bac0ce0bf9f8f
|
||||
F src/test_demovfs.c 86142ba864d4297d54c5b2e972e74f3141ae4b30f05b3a95824184ed2d3d7f91
|
||||
F src/test_devsym.c 6109b45c3db3ef7b002320947ed448c027356ab8b885156ff535fd8684d4a571
|
||||
F src/test_devsym.c aff2255ea290d7718da08af30cdf18e470ff7325a5eff63e0057b1496ed66593
|
||||
F src/test_fs.c ba1e1dc18fd3159fdba0b9c4256f14032159785320dfbd6776eb9973cb75d480
|
||||
F src/test_func.c 181f992e5495644434c4f0e3cc72362a78c295eb2cf3ff4d02498b8bde7aa276
|
||||
F src/test_hexio.c 9478e56a0f08e07841a014a93b20e4ba2709ab56d039d1ca8020e26846aa19bd
|
||||
@ -594,7 +594,7 @@ F src/test_tclsh.c eeafce33ad2136d57e5dec10f1e9a4347447eb72ffd504a1c7b9c6bfe2e71
|
||||
F src/test_tclvar.c 33ff42149494a39c5fbb0df3d25d6fafb2f668888e41c0688d07273dcb268dfc
|
||||
F src/test_thread.c 269ea9e1fa5828dba550eb26f619aa18aedbc29fd92f8a5f6b93521fbb74a61c
|
||||
F src/test_vdbecov.c f60c6f135ec42c0de013a1d5136777aa328a776d33277f92abac648930453d43
|
||||
F src/test_vfs.c 36822d696789535bdd0260f07d2c9a46546082fea8bb1d0a7354c7f9366e37ea
|
||||
F src/test_vfs.c 2cc38a79892017702d13da79ad5152c196eec19bbd67fbde4d88065aac894a84
|
||||
F src/test_vfstrace.c bab9594adc976cbe696ff3970728830b4c5ed698
|
||||
F src/test_windirent.c a895e2c068a06644eef91a7f0a32182445a893b9a0f33d0cdb4283dca2486ac1
|
||||
F src/test_windirent.h 90dfbe95442c9762357fe128dc7ae3dc199d006de93eb33ba3972e0a90484215
|
||||
@ -1882,7 +1882,7 @@ F vsixtest/vsixtest.tcl 6a9a6ab600c25a91a7acc6293828957a386a8a93
|
||||
F vsixtest/vsixtest.vcxproj.data 2ed517e100c66dc455b492e1a33350c1b20fbcdc
|
||||
F vsixtest/vsixtest.vcxproj.filters 37e51ffedcdb064aad6ff33b6148725226cd608e
|
||||
F vsixtest/vsixtest_TemporaryKey.pfx e5b1b036facdb453873e7084e1cae9102ccc67a0
|
||||
P c0400f8c0bcb85ba39004feff753eae2f8e82065539e52b5788febd7644c417b
|
||||
R e1c1402cbd7b36c23875003c93c1e06d
|
||||
U drh
|
||||
Z 8d7eee9f9ee229c119f7fa4a4d9e03ee
|
||||
P ad5ab24ebd557e7af1d92ab3fbcb3747c04da5ad4ed779fb6391dc94042687dd
|
||||
R 1cdad7d96c36f2e03dd55b2f6f56718c
|
||||
U dan
|
||||
Z 9709ab64200eaa0e420a4dbfbec12e7d
|
||||
|
@ -1 +1 @@
|
||||
ad5ab24ebd557e7af1d92ab3fbcb3747c04da5ad4ed779fb6391dc94042687dd
|
||||
dd009cd7aec3598e930806907601f4f0f9b0021ea99fa6c5e29e88f1246066ed
|
12
src/test6.c
12
src/test6.c
@ -550,13 +550,16 @@ static int cfDeviceCharacteristics(sqlite3_file *pFile){
|
||||
** Pass-throughs for WAL support.
|
||||
*/
|
||||
static int cfShmLock(sqlite3_file *pFile, int ofst, int n, int flags){
|
||||
return sqlite3OsShmLock(((CrashFile*)pFile)->pRealFile, ofst, n, flags);
|
||||
sqlite3_file *pReal = ((CrashFile*)pFile)->pRealFile;
|
||||
return pReal->pMethods->xShmLock(pReal, ofst, n, flags);
|
||||
}
|
||||
static void cfShmBarrier(sqlite3_file *pFile){
|
||||
sqlite3OsShmBarrier(((CrashFile*)pFile)->pRealFile);
|
||||
sqlite3_file *pReal = ((CrashFile*)pFile)->pRealFile;
|
||||
pReal->pMethods->xShmBarrier(pReal);
|
||||
}
|
||||
static int cfShmUnmap(sqlite3_file *pFile, int delFlag){
|
||||
return sqlite3OsShmUnmap(((CrashFile*)pFile)->pRealFile, delFlag);
|
||||
sqlite3_file *pReal = ((CrashFile*)pFile)->pRealFile;
|
||||
return pReal->pMethods->xShmUnmap(pReal, delFlag);
|
||||
}
|
||||
static int cfShmMap(
|
||||
sqlite3_file *pFile, /* Handle open on database file */
|
||||
@ -565,7 +568,8 @@ static int cfShmMap(
|
||||
int w, /* True to extend file if necessary */
|
||||
void volatile **pp /* OUT: Mapped memory */
|
||||
){
|
||||
return sqlite3OsShmMap(((CrashFile*)pFile)->pRealFile, iRegion, sz, w, pp);
|
||||
sqlite3_file *pReal = ((CrashFile*)pFile)->pRealFile;
|
||||
return pReal->pMethods->xShmMap(pReal, iRegion, sz, w, pp);
|
||||
}
|
||||
|
||||
static const sqlite3_io_methods CrashFileVtab = {
|
||||
|
@ -191,7 +191,7 @@ static int devsymDeviceCharacteristics(sqlite3_file *pFile){
|
||||
*/
|
||||
static int devsymShmLock(sqlite3_file *pFile, int ofst, int n, int flags){
|
||||
devsym_file *p = (devsym_file *)pFile;
|
||||
return sqlite3OsShmLock(p->pReal, ofst, n, flags);
|
||||
return p->pReal->pMethods->xShmLock(p->pReal, ofst, n, flags);
|
||||
}
|
||||
static int devsymShmMap(
|
||||
sqlite3_file *pFile,
|
||||
@ -201,15 +201,15 @@ static int devsymShmMap(
|
||||
void volatile **pp
|
||||
){
|
||||
devsym_file *p = (devsym_file *)pFile;
|
||||
return sqlite3OsShmMap(p->pReal, iRegion, szRegion, isWrite, pp);
|
||||
return p->pReal->pMethods->xShmMap(p->pReal, iRegion, szRegion, isWrite, pp);
|
||||
}
|
||||
static void devsymShmBarrier(sqlite3_file *pFile){
|
||||
devsym_file *p = (devsym_file *)pFile;
|
||||
sqlite3OsShmBarrier(p->pReal);
|
||||
p->pReal->pMethods->xShmBarrier(p->pReal);
|
||||
}
|
||||
static int devsymShmUnmap(sqlite3_file *pFile, int delFlag){
|
||||
devsym_file *p = (devsym_file *)pFile;
|
||||
return sqlite3OsShmUnmap(p->pReal, delFlag);
|
||||
return p->pReal->pMethods->xShmUnmap(p->pReal, delFlag);
|
||||
}
|
||||
|
||||
|
||||
|
@ -895,7 +895,8 @@ static int tvfsShmMap(
|
||||
Testvfs *p = (Testvfs *)(pFd->pVfs->pAppData);
|
||||
|
||||
if( p->isFullshm ){
|
||||
return sqlite3OsShmMap(pFd->pReal, iPage, pgsz, isWrite, pp);
|
||||
sqlite3_file *pReal = pFd->pReal;
|
||||
return pReal->pMethods->xShmMap(pReal, iPage, pgsz, isWrite, pp);
|
||||
}
|
||||
|
||||
if( 0==pFd->pShm ){
|
||||
@ -945,7 +946,8 @@ static int tvfsShmLock(
|
||||
char zLock[80];
|
||||
|
||||
if( p->isFullshm ){
|
||||
return sqlite3OsShmLock(pFd->pReal, ofst, n, flags);
|
||||
sqlite3_file *pReal = pFd->pReal;
|
||||
return pReal->pMethods->xShmLock(pReal, ofst, n, flags);
|
||||
}
|
||||
|
||||
if( p->pScript && p->mask&TESTVFS_SHMLOCK_MASK ){
|
||||
@ -1009,7 +1011,8 @@ static void tvfsShmBarrier(sqlite3_file *pFile){
|
||||
}
|
||||
|
||||
if( p->isFullshm ){
|
||||
sqlite3OsShmBarrier(pFd->pReal);
|
||||
sqlite3_file *pReal = pFd->pReal;
|
||||
pReal->pMethods->xShmBarrier(pReal);
|
||||
return;
|
||||
}
|
||||
}
|
||||
@ -1025,7 +1028,8 @@ static int tvfsShmUnmap(
|
||||
TestvfsFd **ppFd;
|
||||
|
||||
if( p->isFullshm ){
|
||||
return sqlite3OsShmUnmap(pFd->pReal, deleteFlag);
|
||||
sqlite3_file *pReal = pFd->pReal;
|
||||
return pReal->pMethods->xShmUnmap(pReal, deleteFlag);
|
||||
}
|
||||
|
||||
if( !pBuffer ) return SQLITE_OK;
|
||||
|
Loading…
Reference in New Issue
Block a user