This is the mail archive of the
cygwin-cvs@cygwin.com
mailing list for the Cygwin project.
[newlib-cygwin] Cygwin: utils: ps: use fputs to print fixed strings
- From: Corinna Vinschen <corinna at sourceware dot org>
- To: cygwin-cvs at sourceware dot org
- Date: 9 Aug 2018 06:41:30 -0000
- Subject: [newlib-cygwin] Cygwin: utils: ps: use fputs to print fixed strings
https://sourceware.org/git/gitweb.cgi?p=newlib-cygwin.git;h=423fc83dfd072ab11fadd8cd50b4189c2603670f
commit 423fc83dfd072ab11fadd8cd50b4189c2603670f
Author: Corinna Vinschen <corinna@vinschen.de>
Date: Thu Aug 9 08:41:18 2018 +0200
Cygwin: utils: ps: use fputs to print fixed strings
Avoid gcc warning "format not a string literal and no format arguments"
Signed-off-by: Corinna Vinschen <corinna@vinschen.de>
Diff:
---
winsup/utils/ps.cc | 6 +++---
1 file changed, 3 insertions(+), 3 deletions(-)
diff --git a/winsup/utils/ps.cc b/winsup/utils/ps.cc
index be2ae60..ad46ab7 100644
--- a/winsup/utils/ps.cc
+++ b/winsup/utils/ps.cc
@@ -223,11 +223,11 @@ main (int argc, char *argv[])
}
if (sflag)
- printf (dtitle);
+ fputs (dtitle, stdout);
else if (fflag)
- printf (ftitle);
+ fputs (ftitle, stdout);
else if (lflag)
- printf (ltitle);
+ fputs (ltitle, stdout);
(void) cygwin_internal (CW_LOCK_PINFO, 1000);