瀏覽代碼

(pax_sparse_member_p): Checking member size vs. file size is not reliable enough. Use sparse_map_avail.

Sergey Poznyakoff 20 年之前
父節點
當前提交
2e9ea5f4a7
共有 1 個文件被更改,包括 1 次插入1 次删除
  1. 1 1
      src/sparse.c

+ 1 - 1
src/sparse.c

@@ -845,7 +845,7 @@ static struct tar_sparse_optab const star_optab = {
 static bool
 pax_sparse_member_p (struct tar_sparse_file *file)
 {
-  return file->stat_info->archive_file_size != file->stat_info->stat.st_size;
+  return file->stat_info->sparse_map_avail > 0;
 }
 
 static bool