Source-Changes-HG archive

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

[src/trunk]: src/usr.bin/error Simplify



details:   https://anonhg.NetBSD.org/src/rev/a06e6875c1cd
branches:  trunk
changeset: 765327:a06e6875c1cd
user:      joerg <joerg%NetBSD.org@localhost>
date:      Tue May 24 12:24:22 2011 +0000

description:
Simplify

diffstat:

 usr.bin/error/touch.c |  13 +++++++------
 1 files changed, 7 insertions(+), 6 deletions(-)

diffs (34 lines):

diff -r c4360fec250e -r a06e6875c1cd usr.bin/error/touch.c
--- a/usr.bin/error/touch.c     Tue May 24 12:19:11 2011 +0000
+++ b/usr.bin/error/touch.c     Tue May 24 12:24:22 2011 +0000
@@ -1,4 +1,4 @@
-/*     $NetBSD: touch.c,v 1.25 2011/05/21 00:43:52 christos Exp $      */
+/*     $NetBSD: touch.c,v 1.26 2011/05/24 12:24:22 joerg Exp $ */
 
 /*
  * Copyright (c) 1980, 1993
@@ -34,7 +34,7 @@
 #if 0
 static char sccsid[] = "@(#)touch.c    8.1 (Berkeley) 6/6/93";
 #endif
-__RCSID("$NetBSD: touch.c,v 1.25 2011/05/21 00:43:52 christos Exp $");
+__RCSID("$NetBSD: touch.c,v 1.26 2011/05/24 12:24:22 joerg Exp $");
 #endif /* not lint */
 
 #include <sys/param.h>
@@ -443,10 +443,11 @@
        my_nerrors = my_files[ix+1] - my_files[ix];
 
        if (my_nerrors != nterrors && !previewed) {
-               fprintf(stdout, terse
-                       ? "Uninserted errors\n"
-                       : ">>Uninserted errors for file \"%s\" follow.\n",
-                       name);
+               if (terse)
+                       printf("Uninserted errors\n");
+               else
+                       printf(">>Uninserted errors for file \"%s\" follow.\n",
+                           name);
        }
 
        EITERATE(erpp, my_files, ix) {



Home | Main Index | Thread Index | Old Index