bug-gnu-utils
[Top][All Lists]
Advanced

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

tiny change: s/fputs/fprintf/


From: Jim Meyering
Subject: tiny change: s/fputs/fprintf/
Date: Sun, 07 May 2006 08:33:01 +0200

I found this laying around.
In case I haven't sent it already...

2006-05-07  Jim Meyering  <address@hidden>

        * src/diff3.c (output_diff3): Use fputs in place of fprintf
        to avoid warning from gcc -Wformat-security.

Index: src/diff3.c
===================================================================
RCS file: /sources/diffutils/diffutils/src/diff3.c,v
retrieving revision 1.46
diff -u -p -r1.46 diff3.c
--- src/diff3.c 13 Mar 2006 19:11:17 -0000      1.46
+++ src/diff3.c 7 May 2006 06:30:49 -0000
@@ -1406,7 +1406,7 @@ output_diff3 (FILE *outputfile, struct d
              line = 0;
              do
                {
-                 fprintf (outputfile, line_prefix);
+                 fputs (line_prefix, outputfile);
                  cp = D_RELNUM (ptr, realfile, line);
                  length = D_RELLEN (ptr, realfile, line);
                  fwrite (cp, sizeof (char), length, outputfile);




reply via email to

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