From dd6094f6c030cb3f098d92a7d54ce4dca21d991b Mon Sep 17 00:00:00 2001 From: Sergey Poznyakoff Date: Sat, 3 Jan 2004 22:25:24 +0000 Subject: [PATCH] Updated invocations of safer_name_suffix --- src/create.c | 4 ++-- src/extract.c | 5 +++-- 2 files changed, 5 insertions(+), 4 deletions(-) diff --git a/src/create.c b/src/create.c index 6e49b59..5292f82 100644 --- a/src/create.c +++ b/src/create.c @@ -1181,7 +1181,7 @@ dump_hard_link (struct tar_stat_info *stat) if ((dup = hash_lookup (link_table, &lp))) { /* We found a link. */ - char const *link_name = safer_name_suffix (dup->name, 1); + char const *link_name = safer_name_suffix (dup->name, true); dup->nlink--; @@ -1277,7 +1277,7 @@ dump_file0 (struct tar_stat_info *stat, char *p, return; assign_string (&stat->orig_file_name, p); - assign_string (&stat->file_name, safer_name_suffix (p, 0)); + assign_string (&stat->file_name, safer_name_suffix (p, false)); if (deref_stat (dereference_option, p, &stat->stat) != 0) { diff --git a/src/extract.c b/src/extract.c index 84e4ecd..e62671e 100644 --- a/src/extract.c +++ b/src/extract.c @@ -572,7 +572,7 @@ extract_archive (void) if (verbose_option) print_header (¤t_stat_info, -1); - file_name = safer_name_suffix (current_stat_info.file_name, 0); + file_name = safer_name_suffix (current_stat_info.file_name, false); if (strip_path_elements) { size_t prefix_len = stripped_prefix_len (file_name, strip_path_elements); @@ -861,7 +861,8 @@ extract_archive (void) again_link: { - char const *link_name = safer_name_suffix (current_stat_info.link_name, 1); + char const *link_name = safer_name_suffix (current_stat_info.link_name, + true); struct stat st1, st2; int e; -- 2.45.2