Age | Commit message (Collapse) | Author |
|
|
|
|
|
|
|
symlinks, even on hosts where that's not supported.
Test that if -R is specified without -H or L, -h is assumed.
Test that chown() is not optimized away.
|
|
|
|
|
|
options are incompatible, and their behavior is undefined with POSIX.
(changed, not_changed): Adjust to match the fact that -h is no longer
specified. Sort names.
|
|
group changed, since chgrp now changes unconditionally. This
complicates the sed script a bit. Do not specify --dereference,
since it's the default (and we want to test this). Adjust output
to match the fact that chgrp no longer optimizes the case of
changing a file's group to the same value as before.
|
|
|
|
|
|
needed. Chown a directory only after chowning its children; this
avoids problems if the new directory ownership doesn't permit
access to the children. Dereference symlinks before doing
ROOT_DEV_INO_CHECK, not after, so that we catch symlinks to /.
Do not optimize away the chown() system call when the file's owner
and group already have the desired value. POSIX does not permit
this optimization. Rely on chown and lchown to do the right
thing with symlinks and/or -1 arguments, now that we have wrappers
to do this. Use ENOTSUPP not ENOSYS, and ignore all ENOTSUPP
errors, not just command-line errors.
(chown_files): Pass FTS_STAT to xfts_open if we don't need file status.
|
|
requires either -H or -L, and -R -h requires -P. If -H, specify
FTS_PHYSICAL as well as FTS_COMFOLLOW; this is faster. Make this
file as much like chown.c as possible.
|
|
requires either -H or -L, and -R -h requires -P. If -H, specify
FTS_PHYSICAL as well as FTS_COMFOLLOW; this is faster. Make this
file as much like chgrp.c as possible.
|
|
|
|
stat, even if the user isn't interested in the results.
This prevents a core dump in cycle_check when FTS_NOSTAT is set.
|
|
|
|
|
|
|
|
(ENOSYS): Remove.
|
|
is what POSIX-2004 specifies.
|
|
|
|
prevented a diagnostic of any operands.
|
|
|
|
|
|
|
|
|
|
Prompted by a suggestion from Kalle Olavi Niemitalo
in http://bugs.debian.org/207035.
(direct_mode): New function.
(do_wipefd): Turn on direct-mode I/O.
(dopass): If a file's first write fails with EINVAL,
turn off direct-mode I/O and retry the write.
|
|
|
|
|
|
|
|
|
|
|
|
how POSIXLY_CORRECT changes tr's behavior.
|
|
|
|
|
|
|
|
|
|
The POSIX SYNOPSIS does not allow this option combination.
|
|
|
|
a write error. Problem reported by Jon Peatfield in:
http://lists.gnu.org/archive/html/bug-coreutils/2004-06/msg00020.html
|
|
|
|
|
|
<http://mail.gnu.org/archive/html/bug-coreutils/2003-08/msg00105.html>
where 'dd' created a file that was too large. The bug was that dd
assumed that the input file offset does not advance after a failed
read; but POSIX says that the input file offset is undefined after
a failed read.
(MAX_BLOCKSIZE): New macro.
(input_seekable, input_seek_errno, input_offset,
input_offset_overflow): New vars.
(scanargs): Reject block sizes greater than MAX_BLOCKSIZE.
(advance_input_offset): New function.
(skip_via_lseek): Set errno to zero when reporting our failure,
so that we don't report based on garbage errno.
(skip): If fdesc is standard input, advance the input offset.
Do not quit if reading, and if noerror was specified;
POSIX seems to require this.
If read fails on output file, report the earlier lseek failure
instead; this fixes a FIXME in dd_copy.
(advance_input_after_read_error): New function.
(dd_copy): Use it, instead of assuming that failed reads
do not advance the file pointer. Advance input offset
after nonfailed reads. Advance only a partial block if
the previous read (before the failed read) succeeded, and
do not generate an output block of zeros in this case.
(main): Determine initial input offset, seekability of input,
and error if it wasn't seekable.
|
|
|
|
|
|
remove a symlink to a file on an off-line NFS-mounted partition.
Reported by David Howells in https://bugzilla.redhat.com/124699.
(write_protected_non_symlink): New function.
Don't invoke euidaccess on symlinks.
(prompt): Use write_protected_non_symlink rather than using
euidaccess directly, being careful not to call lstat twice for a file.
|
|
|
|
does with byte/character ranges.
|
|
|
|
|