In the SQLITE_OPEN_NOFOLLOW processing, distinguish between an I/O error
on the xAccess() call and an actual symlink encounter. FossilOrigin-Name: 2e98b42fcb7bc38e22808a9dc1d7a4231ed08ffa97c9f08f33e6e8cd8726856c
This commit is contained in:
parent
0933aad72c
commit
3c904885b1
12
manifest
12
manifest
@ -1,5 +1,5 @@
|
||||
C Add\ssupport\sfor\sSQLITE_OPEN_NOFOLLOW.
|
||||
D 2019-11-18T17:46:38.780
|
||||
C In\sthe\sSQLITE_OPEN_NOFOLLOW\sprocessing,\sdistinguish\sbetween\san\sI/O\serror\non\sthe\sxAccess()\scall\sand\san\sactual\ssymlink\sencounter.
|
||||
D 2019-11-18T18:43:19.703
|
||||
F .fossil-settings/empty-dirs dbb81e8fc0401ac46a1491ab34a7f2c7c0452f2f06b54ebb845d024ca8283ef1
|
||||
F .fossil-settings/ignore-glob 35175cdfcf539b2318cb04a9901442804be81cd677d8b889fcc9149c21f239ea
|
||||
F LICENSE.md df5091916dbb40e6e9686186587125e1b2ff51f022cc334e886c19a0e9982724
|
||||
@ -513,7 +513,7 @@ F src/os_setup.h 0dbaea40a7d36bf311613d31342e0b99e2536586
|
||||
F src/os_unix.c ca1cc9524cb3ae8d59529fb37944487bec89df2041da7c3890f96dae389c5719
|
||||
F src/os_win.c 48513ab173c3f107571c7d886e157ce32c65e6b2adce030469ce488cce8aaa90
|
||||
F src/os_win.h 7b073010f1451abe501be30d12f6bc599824944a
|
||||
F src/pager.c 46a775fa9cf04f222562d0b7a2531cbe100f46287589446407cf8392f965bfdb
|
||||
F src/pager.c 29eed7c315a20c480673e24196f218579712b25967fca998a0b38f78f7958047
|
||||
F src/pager.h 217921e81eb5fe455caa5cda96061959706bcdd29ddb57166198645ef7822ac3
|
||||
F src/parse.y 17c1ae265e1b92cb1f3f1661b020e3eb31f2d8b9588322d2b6f2b22f25b674c9
|
||||
F src/pcache.c 385ff064bca69789d199a98e2169445dc16e4291fa807babd61d4890c3b34177
|
||||
@ -1849,7 +1849,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 6b67eba54e7b4887a8cdab7537b12a95e9f17bcdaa0b423af5ed5bd91f69f2c6
|
||||
R a2cbd9a120585cca025487bdfa231fb0
|
||||
P cb79c828496a703f1410f61458ebc1e15a92a63412b36f51945b2b5a32ec6e88
|
||||
R 443c019725182a17e713facfb01ae431
|
||||
U drh
|
||||
Z e64f9f4a40bbe1e2a10bb5deeff8bfcf
|
||||
Z 59407263a2a6830b9a0d0ddece8d221e
|
||||
|
@ -1 +1 @@
|
||||
cb79c828496a703f1410f61458ebc1e15a92a63412b36f51945b2b5a32ec6e88
|
||||
2e98b42fcb7bc38e22808a9dc1d7a4231ed08ffa97c9f08f33e6e8cd8726856c
|
@ -4790,11 +4790,9 @@ int sqlite3PagerOpen(
|
||||
const char *z;
|
||||
if( (vfsFlags & SQLITE_OPEN_NOFOLLOW)!=0 ){
|
||||
int isLink = 0;
|
||||
if( sqlite3OsAccess(pVfs, zFilename, SQLITE_ACCESS_SYMLINK, &isLink)==0
|
||||
&& isLink
|
||||
){
|
||||
return SQLITE_CANTOPEN_SYMLINK;
|
||||
}
|
||||
int rc = sqlite3OsAccess(pVfs, zFilename, SQLITE_ACCESS_SYMLINK, &isLink);
|
||||
if( rc==SQLITE_OK && isLink ) rc = SQLITE_CANTOPEN_SYMLINK;
|
||||
if( rc ) return rc;
|
||||
}
|
||||
nPathname = pVfs->mxPathname+1;
|
||||
zPathname = sqlite3DbMallocRaw(0, nPathname*2);
|
||||
|
Loading…
Reference in New Issue
Block a user