diff options
author | Tim Kientzle <kientzle@gmail.com> | 2011-09-04 12:36:08 -0400 |
---|---|---|
committer | Tim Kientzle <kientzle@gmail.com> | 2011-09-04 12:36:08 -0400 |
commit | 3147f6607afa5b6d35d5bafda304a01d7e8ba38e (patch) | |
tree | b2f918488095b26981cbe7f94f161fce6b592d1e /tar/util.c | |
parent | 17f740281995269f3b1185809c0e3b8f812e252c (diff) | |
download | libarchive-3147f6607afa5b6d35d5bafda304a01d7e8ba38e.tar.gz |
Extend the tar test to verify that symlink and hardlink
targets get properly rewritten by default.
Adjust the -s parser so that symlink and hardlink target
rewriting is enabled by default and the 's' or 'S' flags
disable both.
SVN-Revision: 3676
Diffstat (limited to 'tar/util.c')
-rw-r--r-- | tar/util.c | 6 |
1 files changed, 3 insertions, 3 deletions
@@ -366,7 +366,7 @@ edit_pathname(struct bsdtar *bsdtar, struct archive_entry *entry) char *subst_name; int r; - r = apply_substitution(bsdtar, name, &subst_name, 0); + r = apply_substitution(bsdtar, name, &subst_name, 0, 0); if (r == -1) { lafe_warnc(0, "Invalid substitution, skipping entry"); return 1; @@ -382,7 +382,7 @@ edit_pathname(struct bsdtar *bsdtar, struct archive_entry *entry) } if (archive_entry_hardlink(entry)) { - r = apply_substitution(bsdtar, archive_entry_hardlink(entry), &subst_name, 1); + r = apply_substitution(bsdtar, archive_entry_hardlink(entry), &subst_name, 0, 1); if (r == -1) { lafe_warnc(0, "Invalid substitution, skipping entry"); return 1; @@ -393,7 +393,7 @@ edit_pathname(struct bsdtar *bsdtar, struct archive_entry *entry) } } if (archive_entry_symlink(entry) != NULL) { - r = apply_substitution(bsdtar, archive_entry_symlink(entry), &subst_name, 1); + r = apply_substitution(bsdtar, archive_entry_symlink(entry), &subst_name, 1, 0); if (r == -1) { lafe_warnc(0, "Invalid substitution, skipping entry"); return 1; |