mirror of
https://github.com/sqlite/sqlite.git
synced 2025-07-30 19:03:16 +03:00
When extracting links from sqlar archives, clobber any existing file or link, and do not call utimes() to set the timestamp - it looks through the link and operates on the target.
FossilOrigin-Name: 2bf8c3f99ad8b74f707d17272fa12b674bec66082d3e8349ebef3dac42ba0782
This commit is contained in:
@ -165,7 +165,7 @@ foreach {tn tcl} {
|
||||
#
|
||||
# Because it is slow, only do this for $tn==1.
|
||||
if {$tn==1} {
|
||||
do_test 1.$tn.1 {
|
||||
do_test 1.$tn.4 {
|
||||
catchcmd test_ar.db $c1
|
||||
file delete -force ar1
|
||||
after 2000
|
||||
@ -194,4 +194,29 @@ do_test 2.1.1 {
|
||||
regsub -all {ar4} [dir_content ar4] ar2
|
||||
} {ar2/file1 ar2/file2 ar2/junk1}
|
||||
|
||||
# Test symbolic links.
|
||||
#
|
||||
if {$tcl_platform(platform)=="unix"} {
|
||||
populate_dir ar2 {
|
||||
file1 "1234"
|
||||
file2 "3456"
|
||||
}
|
||||
file link ar2/link1 file1
|
||||
|
||||
forcedelete shell8.db
|
||||
forcedelete link1
|
||||
|
||||
do_test 3.1 {
|
||||
catchcmd shell8.db {.ar -C ar2 -c file2 link1 }
|
||||
} {0 {}}
|
||||
|
||||
do_test 3.2 {
|
||||
catchcmd shell8.db {.ar -x}
|
||||
} {0 {}}
|
||||
|
||||
do_test 3.3 {
|
||||
catchcmd shell8.db {.ar -x}
|
||||
} {0 {}}
|
||||
}
|
||||
|
||||
finish_test
|
||||
|
Reference in New Issue
Block a user