]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
declare program_name consistently
authorJim Meyering <meyering@redhat.com>
Mon, 2 Jun 2008 15:47:32 +0000 (17:47 +0200)
committerJim Meyering <meyering@redhat.com>
Mon, 2 Jun 2008 15:47:32 +0000 (17:47 +0200)
* src/base64.c: Likewise.
* src/basename.c: Likewise.
* src/cat.c: Likewise.
* src/chcon.c: Likewise.
* src/chgrp.c: Likewise.
* src/chmod.c: Likewise.
* src/chown.c: Likewise.
* src/chroot.c: Likewise.
* src/cksum.c: Likewise.
* src/comm.c: Likewise.
* src/cp.c: Likewise.
* src/csplit.c: Likewise.
* src/cut.c: Likewise.
* src/date.c: Likewise.
* src/dd.c: Likewise.
* src/df.c: Likewise.
* src/dircolors.c: Likewise.
* src/dirname.c: Likewise.
* src/du.c: Likewise.
* src/echo.c: Likewise.
* src/env.c: Likewise.
* src/expand.c: Likewise.
* src/expr.c: Likewise.
* src/factor.c: Likewise.
* src/fmt.c: Likewise.
* src/fold.c: Likewise.
* src/groups.c: Likewise.
* src/head.c: Likewise.
* src/hostid.c: Likewise.
* src/hostname.c: Likewise.
* src/id.c: Likewise.
* src/install.c: Likewise.
* src/join.c: Likewise.
* src/kill.c: Likewise.
* src/link.c: Likewise.
* src/ln.c: Likewise.
* src/logname.c: Likewise.
* src/ls.c: Likewise.
* src/md5sum.c: Likewise.
* src/mkdir.c: Likewise.
* src/mkfifo.c: Likewise.
* src/mknod.c: Likewise.
* src/mktemp.c: Likewise.
* src/mv.c: Likewise.
* src/nice.c: Likewise.
* src/nl.c: Likewise.
* src/nohup.c: Likewise.
* src/od.c: Likewise.
* src/paste.c: Likewise.
* src/pathchk.c: Likewise.
* src/pinky.c: Likewise.
* src/pr.c: Likewise.
* src/printenv.c: Likewise.
* src/printf.c: Likewise.
* src/ptx.c: Likewise.
* src/pwd.c: Likewise.
* src/readlink.c: Likewise.
* src/rm.c: Likewise.
* src/rmdir.c: Likewise.
* src/runcon.c: Likewise.
* src/seq.c: Likewise.
* src/setuidgid.c: Likewise.
* src/shuf.c: Likewise.
* src/sleep.c: Likewise.
* src/sort.c: Likewise.
* src/split.c: Likewise.
* src/stat.c: Likewise.
* src/stty.c: Likewise.
* src/su.c: Likewise.
* src/sum.c: Likewise.
* src/sync.c: Likewise.
* src/tac.c: Likewise.
* src/tail.c: Likewise.
* src/tee.c: Likewise.
* src/test.c: Likewise.
* src/timeout.c: Likewise.
* src/touch.c: Likewise.
* src/tr.c: Likewise.
* src/true.c: Likewise.
* src/tsort.c: Likewise.
* src/tty.c: Likewise.
* src/uname.c: Likewise.
* src/unexpand.c: Likewise.
* src/uniq.c: Likewise.
* src/unlink.c: Likewise.
* src/uptime.c: Likewise.
* src/users.c: Likewise.
* src/wc.c: Likewise.
* src/who.c: Likewise.
* src/whoami.c: Likewise.
* src/yes.c: Likewise.

91 files changed:
src/base64.c
src/basename.c
src/cat.c
src/chcon.c
src/chgrp.c
src/chmod.c
src/chown.c
src/chroot.c
src/cksum.c
src/comm.c
src/cp.c
src/csplit.c
src/cut.c
src/date.c
src/dd.c
src/df.c
src/dircolors.c
src/dirname.c
src/du.c
src/echo.c
src/env.c
src/expand.c
src/expr.c
src/factor.c
src/fmt.c
src/fold.c
src/groups.c
src/head.c
src/hostid.c
src/hostname.c
src/id.c
src/install.c
src/join.c
src/kill.c
src/link.c
src/ln.c
src/logname.c
src/ls.c
src/md5sum.c
src/mkdir.c
src/mkfifo.c
src/mknod.c
src/mktemp.c
src/mv.c
src/nice.c
src/nl.c
src/nohup.c
src/od.c
src/paste.c
src/pathchk.c
src/pinky.c
src/pr.c
src/printenv.c
src/printf.c
src/ptx.c
src/pwd.c
src/readlink.c
src/rm.c
src/rmdir.c
src/runcon.c
src/seq.c
src/setuidgid.c
src/shuf.c
src/sleep.c
src/sort.c
src/split.c
src/stat.c
src/stty.c
src/su.c
src/sum.c
src/sync.c
src/tac.c
src/tail.c
src/tee.c
src/test.c
src/timeout.c
src/touch.c
src/tr.c
src/true.c
src/tsort.c
src/tty.c
src/uname.c
src/unexpand.c
src/uniq.c
src/unlink.c
src/uptime.c
src/users.c
src/wc.c
src/who.c
src/whoami.c
src/yes.c

index a3a73451e62488465a908504c1d7fe297a86e130..fd9d114dd36c8d308d9bc7d20e2bb2fbf8e35e52 100644 (file)
@@ -38,7 +38,7 @@
 #define AUTHORS proper_name ("Simon Josefsson")
 
 /* The invocation name of this program.  */
-char *program_name;
+char const *program_name;
 
 static const struct option long_options[] = {
   {"decode", no_argument, 0, 'd'},
index ca3d347974a61b1a937d108bbdb97ec7566f368e..fe056fcd6c61229a5dc4e2953b040574a9eeb1a9 100644 (file)
@@ -40,7 +40,7 @@
 #define AUTHORS proper_name ("FIXME unknown")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index 87bcc368bd421ce0c50ed06cf8a64aab2a2b91ec..fd6c9df0d053e6c3b50ca70651e2b6a8e35dc7d4 100644 (file)
--- a/src/cat.c
+++ b/src/cat.c
@@ -52,7 +52,7 @@
 #define max(h,i) ((h) > (i) ? (h) : (i))
 
 /* Name under which this program was invoked.  */
-char *program_name;
+char const *program_name;
 
 /* Name of input file.  May be "-".  */
 static char const *infile;
index 2642bf4a97b31c5f9569f3a900478ca8e12cf45f..dacce2b456c3fa7cb6a5f9c42c8e6159b6770d41 100644 (file)
@@ -56,7 +56,7 @@ enum Verbosity
 };
 
 /* The name the program was run with. */
-char *program_name;
+char const *program_name;
 
 /* If nonzero, and the systems has support for it, change the context
    of symbolic links rather than any files they point to.  */
index d09b84125e8fb1f7cdc1cd68b701a7113080c253..c42fad87f5028a8deb33be2f8d2780fe86a966f2 100644 (file)
@@ -43,7 +43,7 @@
 #endif
 
 /* The name the program was run with. */
-char *program_name;
+char const *program_name;
 
 /* The argument to the --reference option.  Use the group ID of this file.
    This file must exist.  */
index e8a795f2441df23fee473392d834796f5baf04d4..8002ef5f3c817ac39397ad5b8385de07ad14f2d5 100644 (file)
@@ -59,7 +59,7 @@ enum Verbosity
 };
 
 /* The name the program was run with. */
-char *program_name;
+char const *program_name;
 
 /* The desired change to the mode.  */
 static struct mode_change *change;
index 5152de56912deb3f48b00e2b0ce55a7fe691db7c..02e0148f7fbb7650091b277729d2e4ce69ba021a 100644 (file)
@@ -48,7 +48,7 @@
   proper_name ("Jim Meyering")
 
 /* The name the program was run with. */
-char *program_name;
+char const *program_name;
 
 /* The argument to the --reference option.  Use the owner and group IDs
    of this file.  This file must exist.  */
index 85053c97453a05d41fe7bae636f94c565f92ce0f..8081b1696b3078c79f75d092c97fae021701aa9a 100644 (file)
@@ -33,7 +33,7 @@
 #define AUTHORS proper_name ("Roland McGrath")
 
 /* The name this program was run with, for error messages. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index 52c34352ac4b12f5f2d54bcfcb9f9ba9ac97a27e..6f1151484919bce1e90ef0079578f8ab465513f8 100644 (file)
@@ -114,7 +114,7 @@ main (void)
 # define BUFLEN (1 << 16)
 
 /* The name this program was run with.  */
-char *program_name;
+char const *program_name;
 
 static uint_fast32_t const crctab[256] =
 {
index 267ec789ffaabd616740a11fe0948c5cb541700e..4700ca00e0708b71217da57933bdb2459a656f8a 100644 (file)
@@ -40,7 +40,7 @@
 #define min(x, y) ((x) < (y) ? (x) : (y))
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* True if the LC_COLLATE locale is hard.  */
 static bool hard_LC_COLLATE;
index 0a33ec31e0903ec5a1c8ae7b6a13e4e45f52e20f..66304492abf293c56b5dbe3f5a2f770db2a2fdae 100644 (file)
--- a/src/cp.c
+++ b/src/cp.c
@@ -89,7 +89,7 @@ enum
 #define INITIAL_ENTRY_TAB_SIZE 70
 
 /* The invocation name of this program.  */
-char *program_name;
+char const *program_name;
 
 /* True if the kernel is SELinux enabled.  */
 static bool selinux_enabled;
index f8c3c025ff02bd7dfd4b6213482e2174f29ef4d1..7d9904c3e439495ff3ad667bd1931656a1670641 100644 (file)
@@ -129,7 +129,7 @@ static void save_line_to_file (const struct cstring *line);
 void usage (int status);
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* Start of buffer list. */
 static struct buffer_record *head = NULL;
index 554e790c8f69d9d70edd384865ec89105c5611f6..a91cca71676316a4dd9b069e854d82945377bed0 100644 (file)
--- a/src/cut.c
+++ b/src/cut.c
@@ -121,7 +121,7 @@ enum operating_mode
   };
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 static enum operating_mode operating_mode;
 
index 8191ff6381df6fe88d389e5a24ccda0ed4af7ff9..36b282695bca6f12aa2d157b57e556f3f767a3ab 100644 (file)
@@ -78,7 +78,7 @@ ARGMATCH_VERIFY (time_spec_string, time_spec);
 static char const rfc_2822_format[] = "%a, %d %b %Y %H:%M:%S %z";
 
 /* The name this program was run with, for error messages. */
-char *program_name;
+char const *program_name;
 
 /* For long options that have no equivalent short option, use a
    non-character as a pseudo short option, starting with CHAR_MAX + 1.  */
index b1635b8753cfccbda0a6ee6543a129f98021ba09..947e6876c60a649ca47ff3c440d1dbe69982be7f 100644 (file)
--- a/src/dd.c
+++ b/src/dd.c
@@ -129,7 +129,7 @@ enum
   };
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* The name of the input file, or NULL for the standard input. */
 static char const *input_file = NULL;
index 20b8f2158f6cd8961b303940d6d7d8a2abb56fd4..2b320cf9892ba238bb615a86ae6b6a81cd3f17e9 100644 (file)
--- a/src/df.c
+++ b/src/df.c
@@ -43,7 +43,7 @@
   proper_name ("Paul Eggert")
 
 /* Name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* If true, show inode information. */
 static bool inode_format;
index d51d409dbb3acc14b03478aa17f73b2e1183c5b4..55cbd261615baeb4db7ab864e016ac8d867a4b89 100644 (file)
@@ -87,7 +87,7 @@ static struct option const long_options[] =
     {NULL, 0, NULL, 0}
   };
 
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index 928a663c69b2781071ce7a68317de2c443e1715c..3c93d0357b535001f8d0eac9acfd4d5945625b98 100644 (file)
@@ -36,7 +36,7 @@
   proper_name ("Jim Meyering")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index b67b89ceacdd8d20e78179eb317e575d5e9a79cd..8b04b65d1c037d40acb3099cb4df19365d7310d8 100644 (file)
--- a/src/du.c
+++ b/src/du.c
@@ -127,7 +127,7 @@ struct dulevel
 };
 
 /* Name under which this program was invoked.  */
-char *program_name;
+char const *program_name;
 
 /* If true, display counts for all files, not just directories.  */
 static bool opt_all = false;
index 1f3bc778563116c8b042c5bd5097ecf957ce0f1d..4b8f56071ba2c4da5e75a1a1b184cbe046450e0b 100644 (file)
@@ -51,7 +51,7 @@ enum { DEFAULT_ECHO_TO_XPG = false };
 #endif
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index bf8ceb2cadbdd75de47953f6e0ab36955e7a61d7..5103cc927ddf5e536256eb4c2cd5f2f90a2de428 100644 (file)
--- a/src/env.c
+++ b/src/env.c
@@ -97,7 +97,7 @@ int putenv ();
 extern char **environ;
 
 /* The name by which this program was run. */
-char *program_name;
+char const *program_name;
 
 static struct option const longopts[] =
 {
index 17747a5b77634715b81de4d5c1545903ea6f940e..2cce8fbea5effc24a759169dd61df4662537165a 100644 (file)
@@ -52,7 +52,7 @@
 #define OUTPUT_BLOCK 256
 
 /* The name this program was run with.  */
-char *program_name;
+char const *program_name;
 
 /* If true, convert blanks even after nonblank characters have been
    read on the line.  */
index a451ca7088994dc845261fa69c08c4392d08f819..e658402c51b1c6bd5021ffc4e28c25d4643b2b58 100644 (file)
@@ -82,7 +82,7 @@ typedef struct valinfo VALUE;
 static char **args;
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 static VALUE *eval (bool);
 static bool nomoreargs (void);
index c116acdbb55cc69dc29ceab2152f74a33ae523a2..681db362d2b0b0969e545c6aa0e0458c2cdc9b9d 100644 (file)
@@ -60,7 +60,7 @@ static const unsigned char wheel_tab[] =
 #define WHEEL_END (wheel_tab + (sizeof wheel_tab / sizeof wheel_tab[0]))
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index 59f71ca02d11c04403284b247fe7189370d896f3..1f4e1da523ff0dea5b786d0849d303d9d41377e7 100644 (file)
--- a/src/fmt.c
+++ b/src/fmt.c
@@ -168,7 +168,7 @@ static void put_word (WORD *w);
 static void put_space (int space);
 
 /* The name this program was run with.  */
-const char *program_name;
+char const *program_name;
 
 /* Option values.  */
 
index d0d1f82f25e190939a81cfbe8e028541f051d594..8d63a8b52df9241522106753e2a271bc9bb491ca 100644 (file)
@@ -35,7 +35,7 @@
 #define AUTHORS proper_name ("David MacKenzie")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* If nonzero, try to break on whitespace. */
 static bool break_spaces;
index f61e07ab0245fb2f4a49d438227a3b3201724bc9..c67ac6e0ad4c9b69d9fee269845216e35dd202e2 100644 (file)
@@ -30,7 +30,7 @@
 #include "group-list.h"
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* The official name of this program (e.g., no `g' prefix).  */
 #define PROGRAM_NAME "groups"
index 4e9beea4cfdfd64dfedec5df37bff82a253113dd..a52f151cf77b0de10c06af08fd05494712e5d1ce 100644 (file)
@@ -65,7 +65,7 @@ enum header_mode
 };
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* Have we ever read standard input?  */
 static bool have_read_stdin;
index c6bc70f2f35edd1b5efe3c2bdd710762320442ff..e481c1c1e6cfb1ad2de7f7cfd48da8a6f3c63fd7 100644 (file)
@@ -34,7 +34,7 @@
 #define AUTHORS proper_name ("Jim Meyering")
 
 /* The name this program was run with, for error messages. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index e57de818985f8fd7ce33156d08d8f59b3610b243..23aab17b654da4b70876f3cf41e0b24cdd226ba1 100644 (file)
@@ -51,7 +51,7 @@ sethostname (char *name, size_t namelen)
 #endif
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index 533f42868a1df8a2cd67ad04e20dcc0700ad224b..53cb0f47f1136ed396ce4443c6aef99e9a143c34 100644 (file)
--- a/src/id.c
+++ b/src/id.c
@@ -45,7 +45,7 @@ static void print_user (uid_t uid);
 static void print_full_info (const char *username);
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* If true, output user/group name instead of ID number. -n */
 static bool use_name = false;
index 10fcae71f43e4c92b740a1656e2e2c704342e51d..1d902d6ee451d38311278e654b472e3a7939db39 100644 (file)
@@ -93,7 +93,7 @@ static int make_ancestor (char const *dir, char const *component,
 void usage (int status);
 
 /* The name this program was run with, for error messages. */
-char *program_name;
+char const *program_name;
 
 /* The user name that will own the files, or NULL to make the owner
    the current user ID. */
index c14cc1e66595aae0aa06fc2471725b003e5110d4..111f9714c76e74d37978d4763c6548c9d0e85d77 100644 (file)
@@ -80,7 +80,7 @@ struct seq
   };
 
 /* The name this program was run with.  */
-char *program_name;
+char const *program_name;
 
 /* The previous line read from each file. */
 static struct line *prevline[2];
index bd5d9b291bdc98e7e429213ef560c4bedf0558d9..21799076b6e365d22a7267191f6200a940497333 100644 (file)
@@ -61,7 +61,7 @@
 #endif
 \f
 /* The name this program was run with, for error messages.  */
-char *program_name;
+char const *program_name;
 
 static char const short_options[] =
   "0::1::2::3::4::5::6::7::8::9::"
index e4b901d976c196bdd0b471ef6da8cf8902cad171..eeb79e7ff04ef651ca6e6afae0cf4b56188330ea 100644 (file)
@@ -36,7 +36,7 @@
 #define AUTHORS proper_name ("Michael Stone")
 
 /* Name this program was run with.  */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index 9523560f52a9df45ec8f91aa7212b140e2fafebe..4b9c9949a912e2c7bb5e8cfeb037386ef9d7dd30 100644 (file)
--- a/src/ln.c
+++ b/src/ln.c
@@ -58,7 +58,7 @@
 #endif
 
 /* The name by which the program was run, for error messages.  */
-char *program_name;
+char const *program_name;
 
 /* FIXME: document */
 static enum backup_type backup_type;
index 11c6a35ed3a02ec3922638c9854bb91532505014..ec894e216a37b5d256644e0ecbd34859ff2a9899 100644 (file)
@@ -30,7 +30,7 @@
 #define AUTHORS proper_name ("FIXME: unknown")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index 653a905faa3c24bc9e426ebb36758f9b9673568c..9a8ad2defd4fbd5f99132bd169e83b48217160f3 100644 (file)
--- a/src/ls.c
+++ b/src/ls.c
@@ -245,7 +245,7 @@ static void parse_ls_color (void);
 void usage (int status);
 
 /* The name this program was run with.  */
-char *program_name;
+char const *program_name;
 
 /* Initial size of hash table.
    Most hierarchies are likely to be shallower than this.  */
index c0b5ed57109c14f692f564f7754e531f6eb43275..35849728020a23c3cc3f7a6428fd3518c636dcfb 100644 (file)
@@ -121,7 +121,7 @@ static bool warn = false;
 static bool quiet = false;
 
 /* The name this program was run with.  */
-char *program_name;
+char const *program_name;
 
 /* For long options that have no equivalent short option, use a
    non-character as a pseudo short option, starting with CHAR_MAX + 1.  */
index d865407b2cc29c70a4b2c4fdc3dd9bc8d5db0bf1..c2d52deb566e90d2396dfab1bd5dd903847e6fac 100644 (file)
@@ -37,7 +37,7 @@
 #define AUTHORS proper_name ("David MacKenzie")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 static struct option const longopts[] =
 {
index cfe9b51be8a1f7a5177e06f75e1a8a0db1d79b13..5befd45900338c44daa4c1c20c3fc90716b9a417 100644 (file)
@@ -33,7 +33,7 @@
 #define AUTHORS proper_name ("David MacKenzie")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 static struct option const longopts[] =
 {
index b67d88cd2fc829b8ea9469d72741623b5f40b8cd..0cd2d2705b29afd75948b611e327a3719dcba0a3 100644 (file)
@@ -34,7 +34,7 @@
 #define AUTHORS proper_name ("David MacKenzie")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 static struct option const longopts[] =
 {
index c25f4b3d7b837d838dd8a8b05a45d346fe8701ab..114fdc2b1cedaebc228d3f0580027992dfec513f 100644 (file)
@@ -36,7 +36,7 @@
 static const char *default_template = "tmp.XXXXXXXXXX";
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* For long options that have no equivalent short option, use a
    non-character as a pseudo short option, starting with CHAR_MAX + 1.  */
index ffd791438d2e41930a717fc5445437c9ed8d3bbb..090541a4c267c313f7cf6816e626b22310131813 100644 (file)
--- a/src/mv.c
+++ b/src/mv.c
@@ -57,7 +57,7 @@ enum
 };
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* Remove any trailing slashes from each SOURCE argument.  */
 static bool remove_trailing_slashes;
index 03e9e6a8bbbfd75dee777372791e7489656f0191..3981a716381d56d4a9444d2a58a27e983391a25e 100644 (file)
@@ -56,7 +56,7 @@
 #endif
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 static struct option const longopts[] =
 {
index 6154ab6e3f5ffb1721be6f4ad4241b8cf442a279..24e9f9861ccf30aa4e95b0422a86c01b107c2994 100644 (file)
--- a/src/nl.c
+++ b/src/nl.c
@@ -62,7 +62,7 @@ enum section
 };
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* Format of body lines (-b).  */
 static char const *body_type = "t";
index 832659c0a29f4eecd7dc5645c946d8a4d463d243..da639f225c7d25e67ca8ce1edadee3a4a25a965a 100644 (file)
@@ -43,7 +43,7 @@ enum
     NOHUP_FAILURE = 127
   };
 
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index 1007f8c904e717f08b6808a00c954cf1b273e374..9b2f722608a7ee5a7c2083999eb411cbd8f8e0eb 100644 (file)
--- a/src/od.c
+++ b/src/od.c
@@ -114,7 +114,7 @@ struct tspec
   };
 
 /* The name this program was run with.  */
-char *program_name;
+char const *program_name;
 
 /* Convert the number of 8-bit bytes of a binary representation to
    the number of characters (digits + sign if the type is signed)
index cdecd557eae6d658c86803dfc6a1a6f0c4d32b8a..cc61a09d53d8a5449bf76880bd5ab743170081fd 100644 (file)
@@ -55,7 +55,7 @@
 #define EMPTY_DELIM '\0'
 
 /* Name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* If nonzero, we have read standard input at some point. */
 static bool have_read_stdin;
index 21e7acd86e1ebfa27ffa8b2dad905b5374c3f7b3..821fe335b185150eb2128e8f02eaed2fa5fc204a 100644 (file)
@@ -72,7 +72,7 @@
 static bool validate_file_name (char *, bool, bool);
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* For long options that have no equivalent short option, use a
    non-character as a pseudo short option, starting with CHAR_MAX + 1.  */
index d5413ca9525b2515dc7362db724fe4246be01553..b8d453b14f72364bfd224ea8ca62c3a6dc06ae15 100644 (file)
@@ -45,7 +45,7 @@
 char *ttyname ();
 
 /* The name this program was run with. */
-const char *program_name;
+char const *program_name;
 
 /* If true, display the hours:minutes since each user has touched
    the keyboard, or blank if within the last minute, or days followed
index ed2876a7603d2769443f8f8848298f5b91de3c95..28ce71370826dde52f390d8114245f091066f20b 100644 (file)
--- a/src/pr.c
+++ b/src/pr.c
@@ -446,7 +446,7 @@ static void print_sep_string (void);
 static void separator_string (const char *optarg_S);
 
 /* The name under which this program was invoked. */
-char *program_name;
+char const *program_name;
 
 /* All of the columns to print.  */
 static COLUMN *column_vector;
index 24b4d979b9cffc4162ba1fddab17b060c88884f3..b90551cf966a3897a7aebc5668e988b8caba76fa 100644 (file)
@@ -46,7 +46,7 @@ enum { PRINTENV_FAILURE = 2 };
   proper_name ("Richard Mlynarik")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 extern char **environ;
 
index cd3e94a8adf5f8aec2dfea44245ff5e43669faea..7081dccd9d96b0b036b2929433719f73f3940983 100644 (file)
@@ -79,7 +79,7 @@ static char const *const cfcc_msg =
  N_("warning: %s: character(s) following character constant have been ignored");
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index 174b3478bb1e7c8cb2e30370eaa75209af48a301..cdc65137e5ad2bdf6577df6cf041ebafb5bc4ea0 100644 (file)
--- a/src/ptx.c
+++ b/src/ptx.c
@@ -69,7 +69,7 @@
 #define Sword 1
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* Program options.  */
 
index bf20f3f5018c5ced880a04400dac055823c6e77a..adbc5b33dcb315aaeb813368d00c365ae7a03f3e 100644 (file)
--- a/src/pwd.c
+++ b/src/pwd.c
@@ -40,7 +40,7 @@ struct file_name
 };
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index 6f29fec0ed9b00a030c736a032825c832111f1c0..455b56e85289f8cd6d14e52183cb948045372aa8 100644 (file)
@@ -33,7 +33,7 @@
 #define AUTHORS proper_name ("Dmitry V. Levin")
 
 /* Name this program was run with.  */
-char *program_name;
+char const *program_name;
 
 /* If true, do not output the trailing newline.  */
 static bool no_newline;
index 0bcd3c6e735f843a4c3c255a6f3b9fc91179be45..eb90bf2cd49b21ab779d2a11352cbd095b85223f 100644 (file)
--- a/src/rm.c
+++ b/src/rm.c
@@ -67,7 +67,7 @@
   proper_name ("Jim Meyering")
 
 /* Name this program was run with.  */
-char *program_name;
+char const *program_name;
 
 /* For long options that have no equivalent short option, use a
    non-character as a pseudo short option, starting with CHAR_MAX + 1.  */
index b090d7a852675b7ec6217ea21fd564bc4436d0cb..4ed2f7742683fe3fc300de90b86b5ad2d43da178 100644 (file)
@@ -39,7 +39,7 @@
 #define AUTHORS proper_name ("David MacKenzie")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* If true, remove empty parent directories.  */
 static bool remove_empty_parents;
index ca81b412e190855d2ca1af60096cf034d585808b..5f9746cf09ace244745d3e73ddb4f40d301b7160 100644 (file)
@@ -73,7 +73,7 @@ static struct option long_options[] = {
 };
 
 /* The name the program was run with. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index 2277e7eae86834b0f7b4087a5b19c4d9174eeb8e..2fe6ec2674e5c9604744281e99d8acaca05516e2 100644 (file)
--- a/src/seq.c
+++ b/src/seq.c
@@ -44,7 +44,7 @@
 static bool equal_width;
 
 /* The name that this program was run with.  */
-char *program_name;
+char const *program_name;
 
 /* The string used to separate two numbers.  */
 static char const *separator;
index dde5e04fdf2ce35af5569d6dd79b37cce949c169..a6262fe4edd8c0733117c581f0642c388c7459e3 100644 (file)
@@ -39,7 +39,7 @@
 
 #define SETUIDGID_FAILURE 111
 
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index cdba97bc85113baf1c872553db568ccea09733bf..359aeb0c89963b3485fc39b30ae8522cb3ccb7b1 100644 (file)
@@ -37,7 +37,7 @@
 #define AUTHORS proper_name ("Paul Eggert")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index 5ecdb4fd321adc2dd8a9e77f7c4ed77006cadb18..5ae704517a9f9f3ce570570d2c5f106125288bfd 100644 (file)
@@ -36,7 +36,7 @@
   proper_name ("Paul Eggert")
 
 /* The name by which this program was run. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index e0480eeb9e08b518e498733a9322f2b0a712122e..5b272e7b7c94e7d3876a3d55f95ec22837652b0b 100644 (file)
@@ -184,7 +184,7 @@ struct month
 };
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* FIXME: None of these tables work with multibyte character sets.
    Also, there are many other bugs when handling multibyte characters.
index a490c87bc2aa73c94690293c5194066ca1873827..4937e55a818307402f6302266799e406c0c7e623 100644 (file)
@@ -47,7 +47,7 @@
 #define DEFAULT_SUFFIX_LENGTH 2
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* Base name of output files.  */
 static char const *outbase;
index 2129dce12ac65221a8fdccf6a89db5223f615116..7b750a085a62cba027a0c8350cd8b4d47b480795 100644 (file)
@@ -173,7 +173,7 @@ static struct option const long_options[] = {
   {NULL, 0, NULL, 0}
 };
 
-char *program_name;
+char const *program_name;
 
 /* Whether to follow symbolic links;  True for --dereference (-L).  */
 static bool follow_links;
index 5a66098287dd98e44e19e219c4213ed4e8930de7..3441365744199c2c89b646a246c704ff93a01310 100644 (file)
@@ -456,7 +456,7 @@ static struct option longopts[] =
 };
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 static void wrapf (const char *message, ...)
      __attribute__ ((__format__ (__printf__, 1, 2)));
index 746eedc84f7a4141d109cc048ce5fceec21c6acc..d6aaaaa8869c2ea5bb4310fdd6b0b74635223a5a 100644 (file)
--- a/src/su.c
+++ b/src/su.c
@@ -129,7 +129,7 @@ static void run_shell (char const *, char const *, char **, size_t)
      ATTRIBUTE_NORETURN;
 
 /* The name this program was run with.  */
-char *program_name;
+char const *program_name;
 
 /* If true, pass the `-f' option to the subshell.  */
 static bool fast_startup;
index 28bd05235a8a787261fcd7a7fc798dddf50e6008..a2aa94570df7acf5078d234628b650c0076ad08a 100644 (file)
--- a/src/sum.c
+++ b/src/sum.c
@@ -37,7 +37,7 @@
   proper_name ("David MacKenzie")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* True if any of the files read were the standard input. */
 static bool have_read_stdin;
index de41e0cd2e3651de7327217825e3b41b1650bc90..fe09c01ce6238f546e9b86bfd13fa8896c407a8c 100644 (file)
@@ -31,7 +31,7 @@
 #define AUTHORS proper_name ("Jim Meyering")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index ec406416215abe30ab66cca03c2e4964b5ce0d2f..baaf5ed16b72ea79dec14e91877afaaf0b88bec8 100644 (file)
--- a/src/tac.c
+++ b/src/tac.c
@@ -76,7 +76,7 @@ tac -r -s '.\|
 #define WRITESIZE 8192
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* The string that separates the records of the file. */
 static char const *separator;
index a2ea79aea08690082df51a77131264811fb38e68..f6ade24b240368300645225d595b29ea4ad39b2c 100644 (file)
@@ -163,7 +163,7 @@ static uintmax_t max_n_unchanged_stats_between_opens =
   DEFAULT_MAX_N_UNCHANGED_STATS_BETWEEN_OPENS;
 
 /* The name this program was run with.  */
-char *program_name;
+char const *program_name;
 
 /* The process ID of the process (presumably on the current host)
    that is writing to all followed files.  */
index 5a5ea08e0a052dc470356d921da1945aceecde5a..2f1c7bb55ff93ebd4fc151e402eb14c8c457c617 100644 (file)
--- a/src/tee.c
+++ b/src/tee.c
@@ -42,7 +42,7 @@ static bool append;
 static bool ignore_interrupts;
 
 /* The name that this program was run with. */
-char *program_name;
+char const *program_name;
 
 static struct option const long_options[] =
 {
index b546efdb895edd78169cde67630cdbeec4f52225..88579d2ca70ac43798e16debc653faf620f3d606 100644 (file)
@@ -48,7 +48,7 @@
 # include <sys/param.h>
 #endif
 
-char *program_name;
+char const *program_name;
 
 /* Exit status for syntax errors, etc.  */
 enum { TEST_TRUE, TEST_FALSE, TEST_FAILURE };
index d7e344198401381452cfeece241b090c9c564e7e..b393a636a313d3196b139d079fe171347e63c8df 100644 (file)
@@ -83,7 +83,7 @@ static int term_signal = SIGTERM;  /* same default as kill command.  */
 static int monitored_pid;
 static int sigs_to_ignore[NSIG];   /* so monitor can ignore sigs it resends.  */
 
-char *program_name;
+char const *program_name;
 
 static struct option const long_options[] = {
   {"signal", required_argument, NULL, 's'},
index 37b598717f9481573ded7868639a6b1344d4493f..b8e4f2e1c4b9575623445e4682555e95eea71c5a 100644 (file)
@@ -49,7 +49,7 @@
 #define CH_MTIME 2
 
 /* The name by which this program was run. */
-char *program_name;
+char const *program_name;
 
 /* Which timestamps to change. */
 static int change_times;
index d75dee352afe73c96208ad81977366a6035dcb63..532e4f01ac47a53b92780cdb82e7abc7e700f0eb 100644 (file)
--- a/src/tr.c
+++ b/src/tr.c
@@ -194,7 +194,7 @@ es_match (struct E_string const *es, size_t i, char c)
 }
 
 /* The name by which this program was run.  */
-char *program_name;
+char const *program_name;
 
 /* When true, each sequence in the input of a repeated character
    (call it c) is replaced (in the output) by a single occurrence of c
index 54a3c5aec682c5e26889695d8c3592575908c4f9..ae6990a3f463881d61de70a736e8072825ef034e 100644 (file)
@@ -33,7 +33,7 @@
 #define AUTHORS proper_name ("Jim Meyering")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index 468c00c73665b2a8d3fc500824f1c58e11f8e7aa..a68ba04dce0a395b95245e8b6da716875b06ec17 100644 (file)
@@ -60,7 +60,7 @@ struct item
 };
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* The head of the sorted list.  */
 static struct item *head = NULL;
index e5cfcb4fdea4c7cb2f864d6f5d36c28073ac28c6..fe19b0110f1af1f669536c2d9b2928c995313c55 100644 (file)
--- a/src/tty.c
+++ b/src/tty.c
@@ -43,7 +43,7 @@ enum
 #define AUTHORS proper_name ("David MacKenzie")
 
 /* The name under which this program was run. */
-char *program_name;
+char const *program_name;
 
 /* If true, return an exit status but produce no output. */
 static bool silent;
index 82261e66c70a0126d3afaf051c0923fa69cf5ede..4691afc5cbae2a8a8ef9241d22b4e4562a0d5bf3 100644 (file)
@@ -87,7 +87,7 @@
 #define PRINT_OPERATING_SYSTEM 128
 
 /* The name this program was run with, for error messages. */
-char *program_name;
+char const *program_name;
 
 static struct option const uname_long_options[] =
 {
index 6a60b20b2bf7b55a13e528ec087cbf04dd890b6a..1fc65d39e58ea3e310dfb8d5db617008d0b63043 100644 (file)
@@ -53,7 +53,7 @@
 #define OUTPUT_BLOCK 256
 
 /* The name this program was run with.  */
-char *program_name;
+char const *program_name;
 
 /* If true, convert blanks even after nonblank characters have been
    read on the line.  */
index e375ab44b078c6609d1ae3ca442091b71ce77305..f8948e26ab10454ef440731f8471d564c68392fb 100644 (file)
@@ -51,7 +51,7 @@
   while (0)
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* True if the LC_COLLATE locale is hard.  */
 static bool hard_LC_COLLATE;
index 26efb66823b71158aae613a7e11c7f28d817c666..0ef24480eccb3df5e3882bea31a86d22c11aba68 100644 (file)
@@ -36,7 +36,7 @@
 #define AUTHORS proper_name ("Michael Stone")
 
 /* Name this program was run with.  */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index 1165f947a22eb05b6ee7af4361c5d35dc3b806b9..1179ce56886432a8faf88dbfa8b7dcbc43a433ea 100644 (file)
@@ -48,7 +48,7 @@
 int getloadavg ();
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 static void
 print_uptime (size_t n, const STRUCT_UTMP *this)
index 745b2bca1534e07bf5d7fbf4828e8a718eec60ba..b1e8b3d8b0b1a835cc30b45c293458e9dcabdd75 100644 (file)
@@ -36,7 +36,7 @@
   proper_name ("David MacKenzie")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 static int
 userid_compare (const void *v_a, const void *v_b)
index 0fd138d070fa527058ea11b3a72a4a3905b6fbde..731eb4a47aea934f2a21bd3af1ac68ec4da0cb2c 100644 (file)
--- a/src/wc.c
+++ b/src/wc.c
@@ -50,7 +50,7 @@
 #define BUFFER_SIZE (16 * 1024)
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* Cumulative number of lines, words, chars and bytes in all files so far.
    max_line_length is the maximum over all files processed so far.  */
index 73c7feab7d01398f51d1147f9aa90dad0a4fc582..bec924fb212e037538a69b69151348a5876c7d98 100644 (file)
--- a/src/who.c
+++ b/src/who.c
@@ -99,7 +99,7 @@
 char *ttyname ();
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 /* If true, attempt to canonicalize hostnames via a DNS lookup. */
 static bool do_lookup;
index eca03f30ec019e040cd5ea6b003bc2676f90aa3f..7686fd0839ead2aba180c72d184fba5ff4fb8b02 100644 (file)
@@ -36,7 +36,7 @@
 #define AUTHORS proper_name ("Richard Mlynarik")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)
index 6cb62f982abd880ba233718f8583d34455eada95..7dec1ecdd9de058eb6bbb7b40505bfdd62d00b44 100644 (file)
--- a/src/yes.c
+++ b/src/yes.c
@@ -32,7 +32,7 @@
 #define AUTHORS proper_name ("David MacKenzie")
 
 /* The name this program was run with. */
-char *program_name;
+char const *program_name;
 
 void
 usage (int status)