]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
* src/copy.c (copy_internal): Add a comment saying why we prefer
authorJim Meyering <jim@meyering.net>
Sat, 21 Oct 2006 07:16:19 +0000 (07:16 +0000)
committerJim Meyering <jim@meyering.net>
Sat, 21 Oct 2006 07:16:19 +0000 (07:16 +0000)
mknod over mkfifo.

ChangeLog
src/copy.c

index fee7654447b5846cdd09179ae6f5b93544f358fb..260955c3951ef6e9f785df86c6efd1abf2179fd6 100644 (file)
--- a/ChangeLog
+++ b/ChangeLog
@@ -1,5 +1,8 @@
 2006-10-21  Jim Meyering  <jim@meyering.net>
 
+       * src/copy.c (copy_internal): Add a comment saying why we prefer
+       mknod over mkfifo.
+
        Enable an fts optimization (call lstat only for directories,
        on some file system types) also with the --preserve-root option
        of chown or chgrp.
index 3cc80945938ca5882855cfb65008b82a00ad0def..5b66b281d4f1b7998a27aebe163790f703196d05 100644 (file)
@@ -1634,6 +1634,9 @@ copy_internal (char const *src_name, char const *dst_name,
     }
   else if (S_ISFIFO (src_mode))
     {
+      /* Use mknod, rather than mkfifo, because the former preserves
+        the special mode bits of a fifo on Solaris 10, while mkfifo
+        does not.  */
       if (mknod (dst_name, src_mode, 0) != 0)
        {
          error (0, errno, _("cannot create fifo %s"), quote (dst_name));