[Top][All Lists]

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

Re: update needed to mknod man page

From: Jim Meyering
Subject: Re: update needed to mknod man page
Date: Sat, 14 Dec 2002 15:21:44 +0100

Kristin E Thomas <address@hidden> wrote:
> I work in documentation in the Linux Technology Center at IBM, and I was
> assigned a bug related to the mknod man page.  It looks like a line should
> be added to the description explaining that the permission mode is
> processed as an octal (like in the description for chmod).  I have attached
> the bug description for our bugzilla below.

Thank you for forwarding that.

The documentation already says that the MODE is interpreted
just as for chmod.

I've made the following changes to specify how the major and
minor numbers are interpreted.  They'll appear in the next test
release.  The latest test release is here:

  (coreutils is the union of fileutils, textutils, and sh-utils)

For information on the mailing lists associated with the
coreutils package, see these:



Index: doc/coreutils.texi
RCS file: /fetish/cu/doc/coreutils.texi,v
retrieving revision 1.79
diff -u -p -u -p -r1.79 coreutils.texi
--- coreutils.texi      6 Dec 2002 15:38:34 -0000       1.79
+++ coreutils.texi      14 Dec 2002 13:23:19 -0000
@@ -7192,6 +7192,9 @@ for a character special file
 When making a block or character special file, the major and minor
 device numbers must be given after the file type.
+If a major or minor device number begins with @samp{0x} or @samp{0X},
+it is interpreted as hexadecimal; otherwise, if it begins with @samp{0},
+as octal; otherwise, as decimal.
 The program accepts the following option.  Also see @ref{Common options}.
Index: src/mknod.c
RCS file: /fetish/cu/src/mknod.c,v
retrieving revision 1.73
retrieving revision 1.74
diff -u -p -u -r1.73 -r1.74
--- src/mknod.c 31 Aug 2002 08:52:10 -0000      1.73
+++ src/mknod.c 14 Dec 2002 14:15:38 -0000      1.74
@@ -15,17 +15,7 @@
    along with this program; if not, write to the Free Software Foundation,
    Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA.  */
-/* Usage: mknod [-m mode] [--mode=mode] path {bcu} major minor
-               make a block or character device node
-          mknod [-m mode] [--mode=mode] path p
-               make a FIFO (named pipe)
-   Options:
-   -m, --mode=mode     Set the mode of created nodes to MODE, which is
-                       symbolic as in chmod and uses the umask as a point of
-                       departure.
-   David MacKenzie <address@hidden>  */
+/* Written by David MacKenzie <address@hidden>  */
 #include <config.h>
 #include <stdio.h>
@@ -62,7 +52,8 @@ usage (int status)
-      printf (_("Usage: %s [OPTION]... NAME TYPE [MAJOR MINOR]\n"), 
+      printf (_("Usage: %s [OPTION]... NAME TYPE [MAJOR MINOR]\n"),
+             program_name);
       fputs (_("\
 Create the special file NAME of the given TYPE.\n\
@@ -77,7 +68,12 @@ Mandatory arguments to long options are 
       fputs (VERSION_OPTION_DESCRIPTION, stdout);
       fputs (_("\
-MAJOR MINOR are forbidden for TYPE p, mandatory otherwise.  TYPE may be:\n\
+Both MAJOR and MINOR must be specified when TYPE is b, c, or u, and they\n\
+must be omitted when TYPE is p.  If MAJOR or MINOR begins with 0x or 0X,\n\
+it is interpreted as hexadecimal; otherwise, if it begins with 0, as octal;\n\
+otherwise, as decimal.  TYPE may be:\n\
+"), stdout);
+      fputs (_("\
   b      create a block (buffered) special file\n\
   c, u   create a character (unbuffered) special file\n\

reply via email to

[Prev in Thread] Current Thread [Next in Thread]