| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
| |
* doc/genfile.texi: Document changes.
* tests/genfile.c: New options: --set-time and --no-dereference.
|
|
|
|
|
|
|
| |
UPDATE_COPYRIGHT_USE_INTERVALS=1 \
UPDATE_COPYRIGHT_MAX_LINE_LENGTH=79 \
gnulib/build-aux/update-copyright \
$(git ls-files | sed -e '/^gnulib$/d; /^COPYING$/d')
|
|
|
|
|
| |
* tests/genfile.c (PRINT_INT): Put statement body
inside do-while to avoid if-else issues.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
It’s now safe to assume C99 sprintf %jd, etc.
* am/system.m4 (PU_SYSTEM): Do not require gl_INTTOSTR.
* gnulib.modules, paxlib.modules:
Remove inttostr. Add strtoimax, strtoumax.
* lib/system.h (UINTMAX_STRSIZE_BOUND): Remove.
* paxlib/error.c (chown_error_details, read_error_details)
(read_warn_details, read_fatal_details, seek_error_details)
(seek_warn_details, write_error_details):
* paxlib/rtape.c (rmt_read, rmt_write, rmt_lseek, rmt_ioctl):
* rmt/rmt.c (rmt_reply):
* tests/genfile.c (verify_file, print_stat):
Use C99 printf formats instead of doing it by hand.
* paxlib/paxlib.h, rmt/rmt.c, tests/genfile.c:
Do not include inttostr.h.
* paxlib/paxlib.h (STRINGIFY_BIGINT): Remove.
* tests/argcv.c (xtonum): Use strtol for signed int, not strtoul.
* tests/genfile.c (checkpoint, verify_file, parse_opt)
(exec_checkpoint, process_checkpoint, exec_command):
Prefer uintmax_t to size_t for counters unrelated to object size.
(PRINT_INT): New macro.
(print_stat): Prefer uintmax_t to unsigned for modes.
|
|
|
|
|
|
|
|
|
| |
* lib/system.h (ERRNO_IS_EACCES): Remove. Not used anymore.
(sys_reset_uid_gid): Re-initialize supplementary groups when
switching privileges. Fix ordering of setgid and setuid calls.
* tests/genfile.c (EXIT_USAGE)
(EXIT_UNAVAILABLE): New exit codes.
Use them as appropriate.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This commit introduces interprocess communication between genfile and
subsidiary command in exec mode. Instead of using sleep as part of
the checkpoint action chain (as GNU tar did so far), genfile now inserts
--checkpoint-action=wait=SIGUSR1 into the command line and sends the
process the SIGUSR1 after having finished with the checkpoint. This
eliminates the race condition and speeds up the tests based on exec
mode.
The "wait" action is introduced in GNU tar 1.30.90.
* doc/genfile.texi: Document changes.
* tests/genfile.c (checkpoint_granularity): New variable.
(parse_opt): Optional argument to --run specifies granularity.
(CHECKPOINT_TEXT): Customize for genfile.
(exec_command): Take command as arguments. Insert the --checkpoint
and --checkpoint-action options after the command name. Use checkpoint
action wait=SIGUSR1 for synchronization. Send SIGUSR1 after processing
checkpoint.
|
|
|
|
|
|
|
| |
* tests/genfile.c: Rename --unlink option to --delete, retaining
old name as alias. Call unlink or rmdir depending on the type of
the argument.
* doc/genfile.texi: Document changes.
|
|
|
|
|
|
| |
* tests/genfile.c: New option --quite: suppress error exit if the
created file is not sparse.
* doc/genfile.texi: Document --quiet.
|
|
|
|
| |
* tests/genfile.c (generate_sparse_file): Remove unused 'i'.
|
|
|
|
|
|
|
|
| |
* tests/genfile.c (generate_sparse_file): Handle '-' argument
(read from stdin);
If content strings starts with '=', treat it as fragment size and
use default pattern to fill it.
* doc/genfile.texi: Document changes to genfile.
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* lib/rmt.h, lib/rtapelib.c (rmt_command, rmt_dev_name__):
Now pointer to const.
* lib/rtapelib.c (rmt_open__): Check return codes from dup2, close.
Don't mishandle the case when 'pipe' allocates file descriptor 0.
* lib/system.h (sys_reset_uid_gid): Check return codes from
setuid, setgid.
* tests/genfile.c (mkhole, exec_checkpoint):
Check return code from ftruncate.
(mkhole): Don't call fseek twice.
(exec_checkpoint): Check return code from system.
(exec_command): Check return code from pipe.
|
|
|
|
|
|
|
|
|
| |
* doc/.gitignore: Replace getdate.texi with parse-datetime.texi.
* gnulib.modules: Replace getdate with parse-datetime, and
getopt with getopt-gnu.
* paxlib.modules: Replace getopt with getopt-gnu.
* tests/genfile.c: Include parse-datetime.h, not getdate.h.
All instances of get_date replaced with parse_datetime.
|
|
|
|
|
|
|
|
|
|
|
| |
This is a minor cleanup to use the POSIX.1-2008 interface for
setting file time stamps to nanosecond resolution, rather than
the pre-2008 gnulib interface. On older hosts, it falls back
on gnulib's implementation of the POSIX interface.
* configure.ac: Don't check for utimes; it's not used.
* gnulib.modules: Add utimensat.
* tests/genfile.c: Don't include utimens.h.
(exec_checkpoint): Use POSIX utimensat function, not utimens.
|
|
|
|
|
|
|
|
| |
* paxlib/paxlib.h (pax_exit): Remove stray semicolon that I
introduced in the previous patch; sorry about that.
* tests/genfile.c (print_stat): Don't assume that mode_t
promotes to unsigned int when calling a varargs function;
that assumption is not portable.
|
|
|
|
| |
* tests/argcv.c [HAVE_CONFIG_H]: Include config.h
|
|
|
|
|
|
| |
* tests/genfile.c: Change the use of --run option.
Implement --unlink action.
* doc/genfile.texi: Document changes in genfile
|
|
|
|
|
|
| |
* tests/argcv.c (escaped_length, escape_copy, argcv_string): Pass
correct type to ctype macros.
* tests/genfile.c (print_stat, exec_command): Likewise.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
| |
(generate_simple_file, exec_command): Remove unused var.
(print_stat): Avoid GCC warning about uninitialized var.
|
| |
|
| |
|
| |
|
|
|
|
| |
file, unless it goes to stdout.
|
|
|
|
|
| |
followed by a punctuation sign and a number, specifying the mask
to be applied to the mode before printing.
|
| |
|
| |
|
|
|
|
| |
the function prototypes.
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
* gnulib.modules: Add inttostr, quote, quotearg.
* lib/system.h (TYPE_SIGNED, TYPE_MINIMUM, TYPE_MAXIMUM): Remove.
(INT_STRLEN_BOUND): Remove.
Include "intprops.h" instead.
(UINTMAX_STRSIZE_BOUND): Define in terms of INT_BUFSIZE_BOUND,
not INT_STRLEN_BOUND.
[HAVE_UTIME_H]: Don't include utime.h.
* paxlib/DISTFILES: Remove convert.c.
* paxlib/convert.c: Remove.
* paxlib/error.c: Include quote.h, quotearg.h.
* paxlib/paxlib.h: Include inttostr.h.
(STRINGIFY_BIGINT): Define in terms of umaxtostr.
(stringify_uintmax_t_backwards): Remove decl.
* tests/genfile.c: Include <utimens.h> instead of rolling our own.
(exec_checkpoint): Use utimens instead of rolling our own.
Don't pass extra args to error.
(main): Wrap message inside _().
|
|
|
|
|
|
|
|
|
|
| |
Include <signal.h>, for 'signal'.
(SIGCHLD) [! defined SIGCHLD && defined SIGCLD]: Define.
(child_exited, sig_child): Remove; not needed.
(exec_command): Use a prototype.
(main): Set SIGCHLD handler to default, not to sig_child.
And do this only if SIGCHLD is defined. This uses the
same pattern that src/tar.c uses.
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
| |
|
|
|