Commit Graph

725 Commits

Author SHA1 Message Date
Paul Eggert
0e041a7bfe (records_read, records_written): New vars.
(write_archive_to_stdout): Now bool, not int.
(open_archive, flush_write, flush_read): Keep records_read and
records_written up to date.
2001-09-22 00:47:09 +00:00
Paul Eggert
85f651c8c6 (recent_long_name, recent_long_link, recent_long_name_blocks,
recent_long_link_blocks): New vars.
(read_and): Pass 0 to read_header.
(read_header): New arg RAW_EXTENDED_HEADERS.  Store away extended headers
into new vars.  Null-terminate incoming symbolic links.
2001-09-22 00:47:09 +00:00
Paul Eggert
6c9e824ce5 (extract_archive): When marking a directory to be updated after
symlinks, stat all directories after it in the delayed-set-stat
list too, since they will be checked after symlinks.
Add support for --overwrite-dir.
2001-09-22 00:47:09 +00:00
Paul Eggert
95a4feb37b (EXTRA_DIST): Remove isc-posix.m4. 2001-09-22 00:47:09 +00:00
Paul Eggert
06e4c77310 (unicode_to_mb): Return int, not void. New arg for failure callback.
(print_unicode_success, print_unicode_failure): New decls.
(print_unicode_char): Return int, not void.
2001-09-21 22:26:45 +00:00
Paul Eggert
a942967415 (EILSEQ, ENOTSUP): New macros, if not defined by errno.h.
(<error.h>): Do not include.
(unicode_to_mb): Return int, not void.  New arg for failure callback.
Invoke the failure callback instead of invoking 'error'.
(print_unicode_success): Renamed from fprintf_callback.  Now extern.
Return -1 on failure, 0 on success.
(print_unicode_failure): New function.
(print_unicode_char): Return int.  Adjust to changes to unicode_to_mb.
Do not report error: instead, print an approximation.
2001-09-21 22:26:45 +00:00
Paul Eggert
92734c1511 Rewrite from scratch, as print-copyr.h. 2001-09-21 22:19:09 +00:00
Paul Eggert
4b5d60ef38 Rewrite from scratch, as print-copyr.c. 2001-09-21 22:19:09 +00:00
Paul Eggert
7a1b6cfa67 (extracting files): Mention --to-stdout.
(Option Summary, Dealing with Old Files): New option --overwrite-dir.
(Overwrite Old Files): Likewise.
2001-09-21 22:19:09 +00:00
Paul Eggert
cc818a584f Add copyright notice. 2001-09-21 21:25:50 +00:00
Paul Eggert
45bf6a9089 Add copyright notice, autoconf 2.52 patch. 2001-09-21 21:22:15 +00:00
Paul Eggert
9957263ec4 From Jim Meyering
(jm_AC_PREREQ_XSTRTOUMAX): Check for declaration of strtoumax
old
2001-09-20 18:01:32 +00:00
Paul Eggert
6fae4f6655 From Jim Meyering
(jm_AC_PREREQ_XSTRTOIMAX): Check for declaration of strtoimax.
2001-09-20 18:01:32 +00:00
Paul Eggert
1589ca47d0 From Jim Meyering.
(strtoimax): Guard declaration with
`#if !HAVE_DECL_STRTOIMAX', rather than just `#ifndef strtoimax'.
The latter fails because some systems (at least rs6000-ibm-aix4.3.3.0)
have their own, conflicting declaration of strtoimax in sys/inttypes.h.
(strtoumax): Likewise, for completeness (it wasn't necessary).
2001-09-20 18:01:31 +00:00
Paul Eggert
e9da8d1a80 Initial revision 2001-09-20 17:08:35 +00:00
Paul Eggert
c80097bb1d Initial revision 2001-09-17 21:44:53 +00:00
Paul Eggert
356b01119e Include stddef.h, for size_t.
Include langinfo.h if needed.
Use locale_charset only if USE_INCLUDED_LIBINTL;
if not, use nl_langinfo (CODESET) if available.
2001-09-15 06:11:37 +00:00
Paul Eggert
698e5f95bf Describe automake patch 2001-09-15 06:10:14 +00:00
Paul Eggert
8267e6ed02 Fix bug: statement before decl. 2001-09-14 02:05:00 +00:00
Paul Eggert
17a96facb7 1.13.23 2001-09-14 01:51:21 +00:00
Paul Eggert
792f268988 Initial revision 2001-09-14 00:27:39 +00:00
Paul Eggert
135a24714f Include copysym.h.
(main): Use copyright_symbol to translate copyright notice,
instead of gettext.
2001-09-14 00:27:39 +00:00
Paul Eggert
8571998faa Include copysym.h.
(decode_options): Use copyright_symbol to translate copyright notice,
instead of gettext.
2001-09-14 00:27:39 +00:00
Paul Eggert
38322a564c (EXTRA_DIST): Add getcwd.m4; remove uintmax_t.m4. 2001-09-14 00:27:39 +00:00
Paul Eggert
95dda72cc6 (struct delayed_set_stat): New member 'after_symlinks'.
(delay_set_stat): Initialize it to 0.
(set_mode): New arg current_stat_info.  Use it (if nonnull) to avoid
taking an extra stat ourselves.  All callers changed.
(set_stat): Likewise.
(apply_nonancestor_delayed_set_stat): New arg 'after_symlinks'.
If false, stop when encountering a struct whose 'after_symlinks' member is
true.  Otherwise, go through all structures but check them more carefully.
All callers changed.
(extract_archive): When extracting a deferred symlink, if its parent
directory's status needs fixing, then mark the directory as needing
to be fixed after symlinks.
(extract_finish): Fix status of ordinary directories, then apply delayed
symlinks, then fix the status of directories that are ancestors
of delayed symlinks.
2001-09-12 06:46:23 +00:00
Paul Eggert
172dc3e72b Remove rexec declaration; it ran afoul of prototypes on Crays. 2001-09-12 06:37:02 +00:00
Paul Eggert
f596d1be2e (HAVE_LONG_LONG): Redefine to HAVE_UNSIGNED_LONG_LONG if unsigned.
(strtoimax): Use sizeof (long), not sizeof strtol (ptr, endptr, base),
to work around bug in IBM C compiler.
2001-09-06 19:47:45 +00:00
Paul Eggert
26d4bfa4b2 Fix typo in quoted strings. 2001-09-03 07:27:00 +00:00
Paul Eggert
2761c42ade Initial revision 2001-09-03 07:22:27 +00:00
Paul Eggert
871b0f0f7e serial 21 2001-09-03 04:17:04 +00:00
Paul Eggert
0e79725f53 Fix typo in local var; from Jim Meyering. 2001-09-03 04:17:04 +00:00
Paul Eggert
9f95e73642 (xgetcwd): Reorganize to avoid some duplication.
Use an initial, malloc'd, buffer of length 128 rather than
a statically allocated one of length 1024.
2001-08-31 11:36:54 +00:00
Paul Eggert
9efbc4be3b (strtoimax): New decl. 2001-08-31 01:36:06 +00:00
Paul Eggert
34ba0c41f9 version 1.13.22. 2001-08-29 21:43:51 +00:00
Paul Eggert
421568c002 (name_gather, addname): Use offsetof when computing sizes for
struct hack; this avoids wasted space in some cases.
(name_gather): Use strcpy, not memcpy.
for consistency with other code that does similar things.
(read_name_from_file, name_next, name_gather, add_hierarchy_to_namelist):
Avoid quadratic behavior when reallocating buffers.
Check for buffer size overflow.
(addname): Avoid unnecessary clearing of memory.
2001-08-29 21:37:27 +00:00
Paul Eggert
eb5c8f4b8b (dump_file): Relativize link names before dumping.
This fixes a bug reported by Jose Pedro Oliveira.
(dump_file): Use offsetof when computing sizes for
struct hack; this avoids wasted space in some cases.
2001-08-29 21:37:27 +00:00
Paul Eggert
4bb7c67e04 (delay_set_stat): Fix off-by-one error in file
name size allocation that caused core dumps.
From Jan.Djarv@mbox200.swipnet.se.
(extract_archive): Use strcpy, not memcpy,
for consistency with other code that does similar things.
2001-08-29 21:37:27 +00:00
Paul Eggert
68867c0103 (main): Use "Copyright %d" to simplify the translator's job in the future.
Advise translator about circle-C.
2001-08-29 06:55:23 +00:00
Paul Eggert
8f207b89cf (decode_options):
Use "Copyright %d" to simplify the translator's job in the future.
Advise translator about circle-C.
2001-08-29 06:55:23 +00:00
Paul Eggert
509ab656f7 Initial revision 2001-08-29 06:36:20 +00:00
Paul Eggert
01c35d7225 Fix copyright notice.
(UNSIGNED): Renamed from STRTOUXMAX_UNSIGNED.
(verify): New macro.
(INT): Renamed from uintmax_t.
(strtoumax, strtoull, strtoul): Remove.
(strtoimax, strtol, strtoll): New macros.
(strtoimax): Renamed from strtoumax.  Interchange signed with unsigned.
Verify sizes at compile-time, not at run-time.
Prefer strtol to strtoll if both work.
(main): Remove.
2001-08-29 06:36:20 +00:00
Paul Eggert
bdafbd14a4 (jm_AC_PREREQ_XSTRTOUMAX): Quote first arg of AC_DEFUN.
Require jm_AC_TYPE_INTMAX_T and jm_AC_TYPE_LONG_LONG since they
is needed to parse the include file.
Simplify logic behind the args to AC_REPLACE.
2001-08-29 06:36:20 +00:00
Paul Eggert
363fc111de (jm_AC_PREREQ_XSTRTOIMAX):
Require jm_AC_TYPE_UINTMAX_T and jm_AC_TYPE_UNSIGNED_LONG_LONG since they
are needed to parse the include file.
Do not require jm_AC_HEADER_INTTYPES_H; it's obsolete.
Check for inttypes.h.
Simplify logic behind the args to AC_REPLACE.
2001-08-29 06:36:20 +00:00
Paul Eggert
cae5fa25ae (jm_AC_HEADER_INTTYPES_H): Remove; now done by autoconf.
(jm_AC_TYPE_INTMAX_T, jm_AC_TYPE_UINTMAX_T): Replace with
Use AC_CHECK_TYPE instead of merely looking for the header.
2001-08-29 06:36:20 +00:00
Paul Eggert
8ff1f155fe (EXTRA_DIST): Add codeset.m4, glibc21.m4, iconv.m4, inttypes.m4,
longlong.m4, xstrtoimax.m4.
2001-08-29 06:36:20 +00:00
Paul Eggert
07c3d5fe32 ("pathmax.h"): Do not include; no longer needed.
(<stdlib.h>, <unistd.h>): Include if available.
("xalloc.h"): Include.
(xmalloc, xstrdup, free): Remove decls; no longer needed.
(xgetcwd): Don't assume sizes fit in 'unsigned'.
Check for overflow when path size gets too large.
Simplify failure code.
2001-08-29 06:36:20 +00:00
Paul Eggert
6790685098 1.13.21 2001-08-29 06:31:47 +00:00
Paul Eggert
195a92a819 (Free Software Needs Free Documentation): New appendix.
`fileds' -> `fields'
2001-08-29 06:31:47 +00:00
Paul Eggert
be4aa5f743 Initial revision 2001-08-29 01:20:18 +00:00
Paul Eggert
bd57de6d97 Fix typo in copying permissions. 2001-08-29 00:43:14 +00:00