mirror of
git://sourceware.org/git/glibc.git
synced 2025-04-12 14:21:18 +08:00
Fix -Wformat-security warnings in posix/regexbug1.c
This commit is contained in:
parent
f627ca82fb
commit
e9813cfb3d
@ -1,3 +1,8 @@
|
||||
2014-12-11 Roland McGrath <roland@hack.frob.com>
|
||||
|
||||
* posix/regexbug1.c (main): Use "%s" format with regerror results,
|
||||
rather than assuming they won't contain any '%'s.
|
||||
|
||||
2014-12-11 Chris Metcalf <cmetcalf@ezchip.com>
|
||||
|
||||
* sysdeps/tile/tilegx/memset.c (__memcpy): Add
|
||||
|
@ -18,7 +18,7 @@ main (void)
|
||||
{
|
||||
char buf[100];
|
||||
regerror (reerr, &re, buf, sizeof buf);
|
||||
error (EXIT_FAILURE, 0, buf);
|
||||
error (EXIT_FAILURE, 0, "%s", buf);
|
||||
}
|
||||
|
||||
if (regexec (&re, "002", 2, ma, 0) != 0)
|
||||
@ -35,7 +35,7 @@ main (void)
|
||||
{
|
||||
char buf[100];
|
||||
regerror (reerr, &re, buf, sizeof buf);
|
||||
error (EXIT_FAILURE, 0, buf);
|
||||
error (EXIT_FAILURE, 0, "%s", buf);
|
||||
}
|
||||
|
||||
if (regexec (&re, "002", 2, ma, 0) != 0)
|
||||
|
Loading…
x
Reference in New Issue
Block a user