]> git.ipfire.org Git - thirdparty/coreutils.git/commitdiff
maint: make spacing around "=" consistent, even in IF_LINT
authorJim Meyering <meyering@redhat.com>
Sat, 15 May 2010 17:36:56 +0000 (19:36 +0200)
committerJim Meyering <meyering@redhat.com>
Mon, 31 May 2010 09:02:21 +0000 (11:02 +0200)
E.g.,
  -  size_t desired_width IF_LINT (= 0);
  +  size_t desired_width IF_LINT ( = 0);
Use this command:
  g grep -l IF_LINT | grep '\.[ch]$' \
    | xargs perl -pi -e 's/(IF_LINT \()= /$1 = /'

17 files changed:
src/chmod.c
src/copy.c
src/cp.c
src/cut.c
src/df.c
src/expand.c
src/expr.c
src/ls.c
src/md5sum.c
src/od.c
src/paste.c
src/pr.c
src/shred.c
src/sort.c
src/truncate.c
src/unexpand.c
src/uniq.c

index 3dab92e68e7d799c23afc1ae9e8e4a93fd53b28a..83f6783df298dc07e8e07f753f2138563dc3bc64 100644 (file)
@@ -180,8 +180,8 @@ process_file (FTS *fts, FTSENT *ent)
   char const *file_full_name = ent->fts_path;
   char const *file = ent->fts_accpath;
   const struct stat *file_stats = ent->fts_statp;
-  mode_t old_mode IF_LINT (= 0);
-  mode_t new_mode IF_LINT (= 0);
+  mode_t old_mode IF_LINT ( = 0);
+  mode_t new_mode IF_LINT ( = 0);
   bool ok = true;
   bool chmod_succeeded = false;
 
index 78c97ccb01237834b04abcca8df7dd8800df68d3..171499c479ad9df710ee3693d307b0d626c592b4 100644 (file)
@@ -1242,7 +1242,7 @@ copy_internal (char const *src_name, char const *dst_name,
   struct stat src_sb;
   struct stat dst_sb;
   mode_t src_mode;
-  mode_t dst_mode IF_LINT (= 0);
+  mode_t dst_mode IF_LINT ( = 0);
   mode_t dst_mode_bits;
   mode_t omitted_permissions;
   bool restore_dst_mode = false;
index cc958d192688c726eb0e873b3a51ec57c2d5dfd2..035526922f28150147c9a19ecd16c08c94ad3482 100644 (file)
--- a/src/cp.c
+++ b/src/cp.c
@@ -405,7 +405,7 @@ make_dir_parents_private (char const *const_dir, size_t src_offset,
         slash++;
       while ((slash = strchr (slash, '/')))
         {
-          struct dir_attr *new IF_LINT (= NULL);
+          struct dir_attr *new IF_LINT ( = NULL);
           bool missing_dir;
 
           *slash = '\0';
index 8c93c8965e60b0da5abf344994e23182020e0f20..5fcf0743a78a5a44a3700c67f3c039de12015e2e 100644 (file)
--- a/src/cut.c
+++ b/src/cut.c
@@ -756,7 +756,7 @@ main (int argc, char **argv)
   int optc;
   bool ok;
   bool delim_specified = false;
-  char *spec_list_string IF_LINT (= NULL);
+  char *spec_list_string IF_LINT ( = NULL);
 
   initialize_main (&argc, &argv);
   set_program_name (argv[0]);
index 40011f8ac23514c83495e24f36f9d2fca20c36a5..f47b3fcc4844b239d80cba12ab835fd4e01a0c71 100644 (file)
--- a/src/df.c
+++ b/src/df.c
@@ -850,7 +850,7 @@ Mandatory arguments to long options are mandatory for short options too.\n\
 int
 main (int argc, char **argv)
 {
-  struct stat *stats IF_LINT (= 0);
+  struct stat *stats IF_LINT ( = 0);
 
   initialize_main (&argc, &argv);
   set_program_name (argv[0]);
index 6a04d36d721cdf48eef72fc625531276105404e2..be50063b6e474ff75ff29ff11c21965d0df2e69e 100644 (file)
@@ -144,8 +144,8 @@ static void
 parse_tab_stops (char const *stops)
 {
   bool have_tabval = false;
-  uintmax_t tabval IF_LINT (= 0);
-  char const *num_start IF_LINT (= NULL);
+  uintmax_t tabval IF_LINT ( = 0);
+  char const *num_start IF_LINT ( = NULL);
   bool ok = true;
 
   for (; *stops; stops++)
index 1ebb4b9d96a09f3e3ac327e0b2247090fafeaa92..dbeaeba89b7a7609a56cea2445bb9d306b85777e 100644 (file)
@@ -547,7 +547,7 @@ trace (fxn)
 static VALUE *
 docolon (VALUE *sv, VALUE *pv)
 {
-  VALUE *v IF_LINT (= NULL);
+  VALUE *v IF_LINT ( = NULL);
   const char *errmsg;
   struct re_pattern_buffer re_buffer;
   char fastmap[UCHAR_MAX + 1];
index 3c0443849b75c2034cbe8a8df118e8cf49aa8fd7..954913085e84d6c3a30fc38c48f02cd15c75812c 100644 (file)
--- a/src/ls.c
+++ b/src/ls.c
@@ -3849,7 +3849,7 @@ quote_name (FILE *out, const char *name, struct quoting_options const *options,
   char smallbuf[BUFSIZ];
   size_t len = quotearg_buffer (smallbuf, sizeof smallbuf, name, -1, options);
   char *buf;
-  size_t displayed_width IF_LINT (= 0);
+  size_t displayed_width IF_LINT ( = 0);
 
   if (len < sizeof smallbuf)
     buf = smallbuf;
index edd21ceb5f8b350a6b88d230430a8c2f45ab8bb2..cbf198645a2fc0ddcf9fea21f1391b39b9132bfa 100644 (file)
@@ -460,9 +460,9 @@ digest_check (const char *checkfile_name)
   line_chars_allocated = 0;
   do
     {
-      char *filename IF_LINT (= NULL);
+      char *filename IF_LINT ( = NULL);
       int binary;
-      unsigned char *hex_digest IF_LINT (= NULL);
+      unsigned char *hex_digest IF_LINT ( = NULL);
       ssize_t line_length;
 
       ++line_number;
index cde3bf951b1be01bc12b1bfbf0ff9b55ed44432d..1d106b1b197a2f503cbbc1c7dd44940af2eb71dc 100644 (file)
--- a/src/od.c
+++ b/src/od.c
@@ -1513,7 +1513,7 @@ main (int argc, char **argv)
   int n_files;
   size_t i;
   int l_c_m;
-  size_t desired_width IF_LINT (= 0);
+  size_t desired_width IF_LINT ( = 0);
   bool modern = false;
   bool width_specified = false;
   bool ok = true;
@@ -1522,7 +1522,7 @@ main (int argc, char **argv)
 
   /* The old-style `pseudo starting address' to be printed in parentheses
      after any true address.  */
-  uintmax_t pseudo_start IF_LINT (= 0);
+  uintmax_t pseudo_start IF_LINT ( = 0);
 
   initialize_main (&argc, &argv);
   set_program_name (argv[0]);
index ca2847fc49dc8373c19545112c4cc3bce1bebc18..36e1cfbc0dd12746b0d5cc6c581e9d708f1d5cb2 100644 (file)
@@ -231,8 +231,8 @@ paste_parallel (size_t nfiles, char **fnamptr)
 
       for (i = 0; i < nfiles && files_open; i++)
         {
-          int chr IF_LINT (= 0);       /* Input character. */
-          int err IF_LINT (= 0);       /* Input errno value.  */
+          int chr IF_LINT ( = 0);      /* Input character. */
+          int err IF_LINT ( = 0);      /* Input errno value.  */
           size_t line_length = 0;      /* Number of chars in line. */
 
           if (fileptr[i])
index 9d4c90f9601e4e089eb8c23845d094abe76cd163..f942151a78f3b479d20e0c89c77684fae06c7ccc 100644 (file)
--- a/src/pr.c
+++ b/src/pr.c
@@ -2437,7 +2437,7 @@ static bool
 read_line (COLUMN *p)
 {
   int c;
-  int chars IF_LINT (= 0);
+  int chars IF_LINT ( = 0);
   int last_input_position;
   int j, k;
   COLUMN *q;
index 659ac5a80edc3879dffaec8fe4f38f4d17f580ec..1da197f368e69ad5abd45e73803f3f002266ae5d 100644 (file)
@@ -365,7 +365,7 @@ dopass (int fd, char const *qname, off_t *sizep, int type,
 {
   off_t size = *sizep;
   off_t offset;                        /* Current file posiiton */
-  time_t thresh IF_LINT (= 0); /* Time to maybe print next status update */
+  time_t thresh IF_LINT ( = 0);        /* Time to maybe print next status update */
   time_t now = 0;              /* Current time */
   size_t lim;                  /* Amount of data to try writing */
   size_t soff;                 /* Offset into buffer for next write */
@@ -388,7 +388,7 @@ dopass (int fd, char const *qname, off_t *sizep, int type,
 
   /* Printable previous offset into the file */
   char previous_offset_buf[LONGEST_HUMAN_READABLE + 1];
-  char const *previous_human_offset IF_LINT (= 0);
+  char const *previous_human_offset IF_LINT ( = 0);
 
   if (lseek (fd, 0, SEEK_SET) == -1)
     {
index 41194ba22fb8b8ceca88917853fca6f3b2544424..5c3da0c4f866524691313c29358d41faf4f2a4f8 100644 (file)
@@ -945,7 +945,7 @@ pipe_fork (int pipefds[2], size_t tries)
   struct tempnode *saved_temphead;
   int saved_errno;
   double wait_retry = 0.25;
-  pid_t pid IF_LINT (= -1);
+  pid_t pid IF_LINT ( = -1);
   struct cs_status cs;
 
   if (pipe (pipefds) < 0)
index 493f7f7912954c642461afd97df2fd07bef7d0b4..610787df7c70bf86f8afc43869a6c88f06d44d49 100644 (file)
@@ -228,7 +228,7 @@ int
 main (int argc, char **argv)
 {
   bool got_size = false;
-  off_t size IF_LINT (= 0);
+  off_t size IF_LINT ( = 0);
   off_t rsize = -1;
   rel_mode_t rel_mode = rm_abs;
   mode_t omode;
index a3bb4a88e950a36281a4360b910019ac5fb48916..e9e5c6acfb86f7476b84934a623a443747b7f9a0 100644 (file)
@@ -163,8 +163,8 @@ static void
 parse_tab_stops (char const *stops)
 {
   bool have_tabval = false;
-  uintmax_t tabval IF_LINT (= 0);
-  char const *num_start IF_LINT (= NULL);
+  uintmax_t tabval IF_LINT ( = 0);
+  char const *num_start IF_LINT ( = NULL);
   bool ok = true;
 
   for (; *stops; stops++)
@@ -450,7 +450,7 @@ int
 main (int argc, char **argv)
 {
   bool have_tabval = false;
-  uintmax_t tabval IF_LINT (= 0);
+  uintmax_t tabval IF_LINT ( = 0);
   int c;
 
   /* If true, cancel the effect of any -a (explicit or implicit in -t),
index 1f594697e993afc17dc5917a22d2ae7e488f6566..df59b12346a8e43341b21ab3612a2ef0cb814639 100644 (file)
@@ -301,8 +301,8 @@ check_file (const char *infile, const char *outfile, char delimiter)
 
   if (output_unique && output_first_repeated && countmode == count_none)
     {
-      char *prevfield IF_LINT (= NULL);
-      size_t prevlen IF_LINT (= 0);
+      char *prevfield IF_LINT ( = NULL);
+      size_t prevlen IF_LINT ( = 0);
 
       while (!feof (stdin))
         {