Commit Graph

1093 Commits

Author SHA1 Message Date
Sergey Poznyakoff
3dbc6a6645 Updated 2004-02-24 15:28:27 +00:00
Sergey Poznyakoff
d8b790047f (decode_header): Call xheader_decode before the assignment to current_stat_info.archive_file_size. 2004-02-24 15:27:54 +00:00
Paul Eggert
fb9a7d180f Invoke AM_ICONV, to define ICONV_CONST if needed. 2004-02-23 22:31:20 +00:00
Sergey Poznyakoff
6a887bbbe5 Updated alpha_1_13_93 2004-02-23 10:07:21 +00:00
Sergey Poznyakoff
9e0d059205 Use prereq() instead of passing arguments to 'before'. 2004-02-23 10:05:42 +00:00
Sergey Poznyakoff
97b9e3d31c Move testing of the prerequisite archive formats
to the separate function 'prereq'. Do not expect any arguments
2004-02-23 10:05:22 +00:00
Sergey Poznyakoff
7add6e4274 Updated 2004-02-23 10:04:49 +00:00
Sergey Poznyakoff
96148abcfe Added UTF-8 support. Finished global extended header support. 2004-02-22 21:00:07 +00:00
Sergey Poznyakoff
a00631babf Give credit to Andreas Schuldei. 2004-02-22 20:55:12 +00:00
Sergey Poznyakoff
b8754a37c7 Use keywords from the global headers.
Correctly handle UTF-8 conversions.
(xheader_list_destroy): New function.
(xheader_set_single_keyword,xheader_set_keyword_equal): Added
missing gettext markers
(decode_record): Rewritten using caller-provided handler and
data closure.
2004-02-22 20:54:44 +00:00
Sergey Poznyakoff
fb766eefb4 Decode encountered global headers. 2004-02-22 20:54:04 +00:00
Sergey Poznyakoff
b1f33c8362 (write_header_name) In pax format, use "path" keyword if the file name is not ASCII 2004-02-22 20:53:27 +00:00
Sergey Poznyakoff
7a8bded5dd Added utf8.c 2004-02-22 20:52:56 +00:00
Sergey Poznyakoff
2de1477b3d Conversions to and from utf-8. 2004-02-22 20:52:34 +00:00
Sergey Poznyakoff
634927b7d2 Detect libiconv 2004-02-22 20:51:10 +00:00
Sergey Poznyakoff
7eeb467132 Minor fix 2004-02-22 20:50:33 +00:00
Sergey Poznyakoff
6847d128e9 Updated 2004-02-21 09:41:19 +00:00
Sergey Poznyakoff
44da0983c0 Sorry, the version number is .93 2004-02-21 09:40:45 +00:00
Sergey Poznyakoff
dfbfc2446f Updated 2004-02-21 09:38:29 +00:00
Sergey Poznyakoff
c145d8a6e3 Added listed01.sh 2004-02-21 09:36:15 +00:00
Sergey Poznyakoff
985199c260 Check listed incremental backups on individual files. 2004-02-21 09:35:44 +00:00
Sergey Poznyakoff
e8af2fec8a Minor stylistic fixes. 2004-02-21 09:35:10 +00:00
Sergey Poznyakoff
ee6aa2bea8 Raised patchlevel to 92a 2004-02-21 09:34:39 +00:00
Sergey Poznyakoff
2ad098dfff Updated 2004-02-21 09:34:22 +00:00
Sergey Poznyakoff
b960c38c4b (dump_file0): The conditional at line
1296 prevented incremental backups on individual files
from working, as reported by Andreas Schuldei
<andreas@schuldei.org>.

This is due to the condition

  (0 < top_level || !incremental_option)

Removing it makes incremental backups work for individual
files as well as for directories. On the other hand, it does
not affect other functionality, as shown by the reasoning below:

To begin with, the two parts of this condition are mutually
superfluous, because

  1) when top_level < 0, incremental_option == 1
  so the condition yields false
  2) when top_level >= 0, incremental_option == 0
  so the condition yields true.

In other words, it is completely equivalent to

      (!incremental_option)

Now, let's consider the effect of its removal. There are two cases:

1) when incremental_option==1
This means incremental backup in progress. In this case dump_file
is invoked only for directories or for files marked with 'Y' by
get_directory_contents. The latter are those that did not meet the
condition in incremen.c:242, which is exactly the same condition
as this at create.c:1296. So, for these files the check
(!incremental_option) is useless, since the rest of the
conditional will yield false anyway. On the other hand, if
dump_file is invoked on a directory, the conditional will yield
false due to !S_ISDIR assertion, so these will be processed as usual.

Thus, for this case the extra condition (!incremental_option) is
irrelevant, and its removal won't alter the behavior of tar,
*except* that it will enable incremental backups on individual
files, which is the wanted effect.

2) when incremental_option==0
In this case the condition yields true and its removal does not
affect the functionality.
2004-02-21 09:33:58 +00:00
Sergey Poznyakoff
ccaedb6b29 Updated 2004-02-20 15:42:41 +00:00
Sergey Poznyakoff
d46025b23c (sort_obstack): Fixed typo in the comment 2004-02-20 15:40:47 +00:00
Sergey Poznyakoff
72ac31581d (decode_header): Call xheader_decode unconditionally. 2004-02-20 15:39:45 +00:00
Sergey Poznyakoff
64cca92a1f (delete_archive_members): Call xheader_decode unconditionally. 2004-02-20 15:39:29 +00:00
Sergey Poznyakoff
c487595864 Require gnu or oldgnu format 2004-02-20 15:36:18 +00:00
Sergey Poznyakoff
29e59e07b1 Require gnu, oldgnu or posix format 2004-02-20 15:35:30 +00:00
Sergey Poznyakoff
74d29bc5de Accept an optional list of allowed archive
formats. Exit with the status 77 if the current archive
format does not match any of them.
2004-02-20 15:35:19 +00:00
Sergey Poznyakoff
069c0d99ae Document new default for extended header names. 2004-02-20 15:34:37 +00:00
Sergey Poznyakoff
f038194718 (xheader_format_name): Bugfix.
(xheader_xhdr_name): Changed the default extended header name
to '%d/PaxHeaders.%p/%f', as POSIX requires.
(xheader_ghdr_name): Removed unused argument.
(xheader_write,xheader_write_global): New function.
(xheader_decode): Modified to honor overrides whatever
the current archive format is.
2004-02-20 15:34:12 +00:00
Sergey Poznyakoff
eff25ef359 (update_archive): Write global extended header if constructed. 2004-02-20 15:33:12 +00:00
Sergey Poznyakoff
b3060eabaf (assert_format): Do not bail out if several
--format arguments are given. This is a common case when
TAR_OPTIONS are used.
(decode_options): New option --show-defaults displays the
compiled-in defaults.

Use POSIX format if no --format option was given and
--pax-option was specified.

Do not allow to use --pax-option unless the archive format is
set to POSIX (or reading subcommand is requested).
2004-02-20 15:32:56 +00:00
Sergey Poznyakoff
93a4273b66 (start_private_header): Removed static qualifier.
(write_extended): Removed superfluous last argument. Use
xheader_write()
(simple_finish_header): New function.
(finish_header): Use simple_finish_header() to break recursive
dependency between this function and write_extended().
2004-02-20 15:32:12 +00:00
Sergey Poznyakoff
17be45c834 (simple_finish_header,start_private_header): New
declarations
(xheader_ghdr_name): Changed declaration
2004-02-20 15:30:26 +00:00
Sergey Poznyakoff
694f427d0e Updated 2004-02-20 11:46:33 +00:00
Sergey Poznyakoff
b4e605a829 Added a comment 2004-02-20 11:45:15 +00:00
Sergey Poznyakoff
b58452bdbd Documented --pax-option 2004-02-20 11:44:46 +00:00
Sergey Poznyakoff
ff541dcac6 Updated 2004-02-18 14:56:56 +00:00
Sergey Poznyakoff
6613170489 Updated 2004-02-18 14:49:08 +00:00
Sergey Poznyakoff
6ac0d0aadd Updated 2004-02-18 14:44:53 +00:00
Sergey Poznyakoff
694e8376ab Minor fixes 2004-02-18 14:41:41 +00:00
Sergey Poznyakoff
440e65ef2c Implement pax -o option. Fixed misleading heading comment (introduced 2003-09-02). 2004-02-18 14:41:23 +00:00
Sergey Poznyakoff
d0eceef438 New option --pax-option (equivalent to -o option of pax). 2004-02-18 14:41:00 +00:00
Sergey Poznyakoff
434f2a22ba (write_extended): Call xheader_xhdr_name
instead of using hardcoded "././@PaxHeader" name.
2004-02-18 14:40:21 +00:00
Sergey Poznyakoff
0bfb6e136d (xheader_xhdr_name,xheader_ghdr_name): New functions 2004-02-18 14:39:36 +00:00
Sergey Poznyakoff
7d31c8176c Added stpcpy 2004-02-18 14:39:24 +00:00