This is the mail archive of the gcc-bugs@gcc.gnu.org mailing list for the GCC project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[Bug other/80895] format not a string literal and no format arguments; in GCC itself


https://gcc.gnu.org/bugzilla/show_bug.cgi?id=80895

--- Comment #1 from Andrew Pinski <pinskia at gcc dot gnu.org> ---
This patch is incorrect:
   /* The gmsgid may be a format string with %< and %>. */
-  warned = pedwarn (exploc, opt, gmsgid);
+  warned = pedwarn (exploc, opt, "%s", gmsgid);

See that comment of why.

Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]