mirror of
git://git.sv.gnu.org/coreutils.git
synced 2026-04-20 18:56:39 +02:00
(copy_internal): Change test of source type from !S_ISREG to S_ISLNK.
Reported by Paul Eggert in http://lists.gnu.org/archive/html/bug-coreutils/2004-10/msg00050.html.
This commit is contained in:
@@ -1081,7 +1081,7 @@ copy_internal (const char *src_path, const char *dst_path,
|
||||
&& (x->unlink_dest_before_opening
|
||||
|| (x->preserve_links && 1 < dst_sb.st_nlink)
|
||||
|| (x->dereference == DEREF_NEVER
|
||||
&& ! S_ISREG (src_sb.st_mode))))
|
||||
&& S_ISLNK (src_sb.st_mode))))
|
||||
{
|
||||
if (unlink (dst_path) && errno != ENOENT)
|
||||
{
|
||||
|
||||
Reference in New Issue
Block a user