Age | Commit message (Collapse) | Author |
|
|
|
a patch from FreeBSD (but this is simpler). Closes PR #821
|
|
the way the user tells us that he really wants a directory. Also, a
trailing slash does not mean that the last component is null (in fact,
according to POSIX, a component can't be 0 bytes). Rather, the last
component is the one directly preceding the trailing slashes.
|
|
|
|
|
|
|
|
Also, use MAXPATHLEN, not MAXPATHLEN+1
|
|
|
|
|
|
|
|
stat the pathname "" in order to decide that the pathname "/" is
a directory. This caused `cp kernel /' to fail if the kernel has
the POSIX behaviour of not allowing the pathname "" to be an alias
for ".". It presumably also caused `cp /etc/motd /' to fail in
the unlikely event that "." is not stat'able.
Be more careful about concatenating pathnames: don't check that
the pathname fits until prefixes have been discarded (the check
was too strict). Print the final pathname in error messages.
Terminate the target directory name properly for error messages.
Don't add a slash between components if there is already a slash.
Fix from FreeBSD
|
|
|
|
|
|
|