]> _ Git - alire.git/commit
Fix unpacking of tarfiles with softlinks to subdirectories (#1382)
authorAlejandro R Mosteo <amosteo@unizar.es>
Wed, 31 May 2023 15:52:44 +0000 (17:52 +0200)
committerGitHub <noreply@github.com>
Wed, 31 May 2023 15:52:44 +0000 (17:52 +0200)
commit9cac98b06d92af1d304005fb2681a2ab671cef56
treee38867c6b76c91a3b99081b8c0a3a4ca6d3c6cef
parent4cb0e97a616da5a1c296639f4798751ecb0de114
Fix unpacking of tarfiles with softlinks to subdirectories (#1382)

* Fix Traverse_Tree for softlinked dirs

Remains: GC.VFS.Remove_Dir fails because of the same reason, probably.

* Manually delete softlinks prior to deleting a dir

Otherwise, depending on the links' targets, both Ada.Directories and
GNATCOLL.VFS had trouble with fully deleting a tree containing such links.

* Test for tarballs containing softlinks

* Self-review

* Skip new test on Windows
src/alire/alire-directories.adb
src/alire/alire-directories.ads
testsuite/tests/install/softlinks/my_index/crate-0.1.0.tgz [new file with mode: 0644]
testsuite/tests/install/softlinks/my_index/index/cr/crate/crate-0.1.0.toml [new file with mode: 0644]
testsuite/tests/install/softlinks/my_index/index/index.toml [new file with mode: 0644]
testsuite/tests/install/softlinks/test.py [new file with mode: 0644]
testsuite/tests/install/softlinks/test.yaml [new file with mode: 0644]