coreutils
[Top][All Lists]
Advanced

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

[PATCH] maint: various cleanups


From: Pádraig Brady
Subject: [PATCH] maint: various cleanups
Date: Sat, 5 Apr 2014 02:00:14 +0100

* tests/misc/numfmt.pl: Fix comment misspelling.
* src/cut.c: Likewise.
* src/tsort.c (detect_loop): Replace an fprintf() with error().
---
 src/cut.c            |    2 +-
 src/tsort.c          |    3 +--
 tests/misc/numfmt.pl |    2 +-
 3 files changed, 3 insertions(+), 4 deletions(-)

diff --git a/src/cut.c b/src/cut.c
index b659a2b..5528068 100644
--- a/src/cut.c
+++ b/src/cut.c
@@ -417,7 +417,7 @@ set_fields (const char *fieldstr)
 
   /* After merging, reallocate RP so we release memory to the system.
      Also add a sentinel at the end of RP, to avoid out of bounds access
-     and for perfomance reasons.  */
+     and for performance reasons.  */
   ++n_rp;
   rp = xrealloc (rp, n_rp * sizeof (struct range_pair));
   rp[n_rp - 1].lo = rp[n_rp - 1].hi = SIZE_MAX;
diff --git a/src/tsort.c b/src/tsort.c
index fb5ff29..661c717 100644
--- a/src/tsort.c
+++ b/src/tsort.c
@@ -347,8 +347,7 @@ detect_loop (struct item *k)
                         {
                           struct item *tmp = loop->qlink;
 
-                          fprintf (stderr, "%s: %s\n", program_name,
-                                   loop->str);
+                          error (0, 0, "%s", loop->str);
 
                           /* Until we encounter K again.  */
                           if (loop == k)
diff --git a/tests/misc/numfmt.pl b/tests/misc/numfmt.pl
index e53b22d..ca3c896 100755
--- a/tests/misc/numfmt.pl
+++ b/tests/misc/numfmt.pl
@@ -260,7 +260,7 @@ my @Tests =
      #   so these are 40 of "M", not 40,000,000.
      ['mix-1', '--suffix=M --from=si 40M',     {OUT=>"40M"}],
 
-     # These are fourty-million Ms .
+     # These are forty-million Ms .
      ['mix-2', '--suffix=M --from=si 40MM',     {OUT=>"40000000M"}],
 
      ['mix-3', '--suffix=M --from=auto 40MM',     {OUT=>"40000000M"}],
-- 
1.7.7.6




reply via email to

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