https://gcc.gnu.org/bugzilla/show_bug.cgi?id=77521
--- Comment #2 from Martin Sebor <msebor at gcc dot gnu.org> --- Author: msebor Date: Fri Sep 9 23:12:10 2016 New Revision: 240059 URL: https://gcc.gnu.org/viewcvs?rev=240059&root=gcc&view=rev Log: PR c/77520 - wrong value for extended ASCII characters in -Wformat message PR c/77521 - %qc format directive should quote non-printable characters gcc/c-family/ChangeLog: PR c/77520 PR c/77521 * c-format.c (argument_parser::find_format_char_info): Use %qc format directive unconditionally. gcc/ChangeLog: PR c/77520 PR c/77521 * pretty-print.c (pp_quoted_string): New function. (pp_format): Call it for %c and %s directives. gcc/testsuite/ChangeLog: PR c/77520 PR c/77521 * gcc.dg/pr77520.c: New test. * gcc.dg/pr77521.c: New test. Added: trunk/gcc/testsuite/gcc.dg/pr77520.c trunk/gcc/testsuite/gcc.dg/pr77521.c Modified: trunk/gcc/ChangeLog trunk/gcc/c-family/ChangeLog trunk/gcc/c-family/c-format.c trunk/gcc/pretty-print.c trunk/gcc/testsuite/ChangeLog