| Commit message (Collapse) | Author | Age | Files | Lines |
|
|
|
|
|
|
|
|
| |
Previously, it would either try to copy it anyway and fail (without -R),
or create fifo instead of the socket (with -R).
Found with: Coverity Prevent
CID: 5623
MFC after: 2 weeks
|
|
|
|
|
|
|
|
|
|
|
|
| |
feature parity with du(1) and similar: When set, cp(1) will not traverse
mount points.
Initial patch by: Graham J Lee leeg teaching.physics.ox.ac.uk
PR: bin/88056
Initial patch by: Graham J Lee leeg teaching.physics.ox.ac.uk
Approved by: ed (mentor)
MFC after: 1 month
|
|
|
|
|
|
| |
compatibility with other implementations.
MFC after: 1 month
|
|
|
|
| |
Submitted by: Peter Jeremy <peterjeremy@optushome.com.au>
|
|
|
|
|
|
|
|
|
| |
warning is given when the directory doesn't exist.
PR: bin/50656
Submitted by: Edwin Groothuis <edwin@mavetju.org>
Approved by: grog@
Not reviewed by: grog@
|
|
|
|
| |
Lesson from: bde
|
|
|
|
|
|
|
|
| |
compatible with old -r behavior with regards to -L. You can now copy fifos
and other special files with -r.
Reviewed by: -standards (long ago), das, bde
Approved by: bde (recently)
|
|
|
|
| |
Overall still not kosher but better matches style(9).
|
|
|
|
|
|
| |
Bikeshedded to death on: hackers
Submitted by:andersonatcenttech.com
MFC in: 1 month
|
|
|
|
| |
Obtained from: NetBSD, Coverity ID 1754
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
This includes adding support for ACLs into cp(1) and mv(1) userspace
utilities.
For mv(1), if _PC_ACL_EXTENDED is in effect for the source AND destination
operands, the destination file's ACLs shall reflect the source.
For cp(1), if _PC_ACL_EXTENDED is in effect for both source and destination
operands, and -p has been specified, the ACLs from the source shall be
preserved on the destination.
MFC after: 1 month
|
| |
|
|
|
|
| |
OK'ed by: imp, core
|
|
|
|
| |
Submitted by: Jun Kuriyama
|
| |
|
|
|
|
|
| |
<sys/param.h>. Include <sys/types.h> instead of of <sys/param.h>
so that further such dependencies don't develop.
|
| |
|
| |
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
| |
the cumulative exit status being overwritten when directory permissions
were being set. This was particularly bad when called from mv(1) to
perform a cross-device move as the original files were deleted even if
the copy failed.
Reported by: Slaven Rezic <slaven.rezic@berlin.de>
Patch by: bde
PR: 42789
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
hack, thereby allowing future extensions to the structure (e.g., for extended
attributes) without rebreaking the ABI. FTSENT now contains a pointer to the
parent stream, which fts_compar() can then take advantage of, avoiding the
undefined behavior previously warned about. As a consequence of this change,
the prototype of the comparison function passed to fts_open() has changed
to reflect the required amount of constness for its use. All callers in the
tree are updated to use the correct prototype.
Comparison functions can now make use of the new parent pointer to access
the new stream-specific private data pointer, which is intended to assist
creation of reentrant library routines which use fts(3) internally.
Not objected to in spirit by: -arch
|
|
|
|
|
|
|
| |
PR: 7828
Suggested by: Daniel O'Connor <doconnor@gsoft.com.au>
Approved by: sheldonh (mentor)
MFC after: 2 weeks
|
|
|
|
| |
happy about it any more so change the usage to make buildworld work again.
|
| |
|
| |
|
|
|
|
|
|
| |
instead of making a copy of the link itself (SUSv3)
Obtained from: NetBSD
|
| |
|
|
|
|
|
|
|
|
|
|
| |
Fix the case:
cp file nonexistent/
which create nonextstent as file while trailing slash clearly indicates
that nonexistent must be a directory.
Also fix the case:
cp file1 file2/
which should produce error.
|
| |
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
| |
o __P has been reoved
o Old-style K&R declarations have been converted to new C89 style
o register has been removed
o prototype for main() has been removed (gcc3 makes it an error)
o int main(int argc, char *argv[]) is the preferred main definition.
o Attempt to not break style(9) conformance for declarations more than
they already are.
Approved by: arch@, new style(9)
|
|
|
|
| |
a combination of my words and his. We will stop fiddling now. :-)
|
|
|
|
|
|
|
| |
circumstances. This is a reworked version of the same fix, that does
not have this defect, and which fixes some style bugs at the same time.
Bug reported and fix reviewed by: bde
|
|
|
|
|
|
|
|
|
|
| |
directories to be copied. Apply umask to newly created directories
when -p is not specified.
PR: 27970
PR: 31633
MFC after: 4 days
|
| |
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
|
| |
the !(pflag && setfile()) case for regular files unless the copy is
owned by the same user and group. These bits have already been lost
(or never gained) in the correct way. The code didn't actually lose
the bits; it depended on them being lost already (apparently in all
cases) and attempted to gain them as necessary, but it often gained
them (and sometimes collateral bits) when wrong:
- pflag && setfile() == 0 case (i.e., for a successful cp -p):
setfile() copies all the attributes as correctly as possible (as
specified by POSIX), and we sometimes messed up the up the mode by
setting it again. Also, if the file is immutable, then setting the
mode again gave spurious errors (PR 20646).
- !pflag case. If the target is created, POSIX requires it to not
have the set[ug]id bits, but we sometimes copied them from the source.
If the target already exists, POSIX requires its mode to be unchanged,
but we sometimes copied the whole mode from the source.
PR: 20646
MFC after: 4 weeks
|
|
|
|
| |
strings.
|
|
|
|
| |
Reviewed by: obrien
|
| |
|
| |
|
|
|
|
|
|
| |
Idea taken from obrien.
Reviewed by: obrien
|
| |
|
|
|
|
| |
Submitted by: Philippe Charnier <charnier@xp11.frmug.org>
|
|
|
|
|
|
|
|
|
|
| |
statement if blocks[*] when the else could be ambiguous, not defaulting
to int type and removal of some unused variables.
[*] This is explicitly allowed by style(9) when the single statement
spans more than one line.
Reviewed by: obrien, chuckr
|
| |
|
| |
|
| |
|
|
|
|
| |
posix standard on the topic.
|
| |
|