forked from Imagelibrary/binutils-gdb
elfedit false "may be used uninitialised"
elfedit.c:904:15: error: 'osabi' may be used uninitialised in this function [-Werror=maybe-uninitialized]
904 | osabi = concat (osabi, "|", osabis[i].name, NULL);
| ^~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~~
* elfedit (usage): Avoid false positive "may be used uninitialised".
Don't leak memory.
This commit is contained in:
@@ -1,3 +1,8 @@
|
|||||||
|
2020-11-09 Alan Modra <amodra@gmail.com>
|
||||||
|
|
||||||
|
* elfedit (usage): Avoid false positive "may be used uninitialised".
|
||||||
|
Don't leak memory.
|
||||||
|
|
||||||
2020-11-09 Howard Chu <hyc@symas.com>
|
2020-11-09 Howard Chu <hyc@symas.com>
|
||||||
|
|
||||||
* ar.c (main): Use plugin_target rather than "target" when
|
* ar.c (main): Use plugin_target rather than "target" when
|
||||||
|
|||||||
@@ -895,13 +895,10 @@ ATTRIBUTE_NORETURN static void
|
|||||||
usage (FILE *stream, int exit_status)
|
usage (FILE *stream, int exit_status)
|
||||||
{
|
{
|
||||||
unsigned int i;
|
unsigned int i;
|
||||||
char *osabi;
|
char *osabi = concat (osabis[0].name, NULL);
|
||||||
|
|
||||||
for (i = 0; i < ARRAY_SIZE (osabis); i++)
|
for (i = 1; i < ARRAY_SIZE (osabis); i++)
|
||||||
if (i == 0)
|
osabi = reconcat (osabi, "|", osabis[i].name, NULL);
|
||||||
osabi = concat (osabis[i].name, NULL);
|
|
||||||
else
|
|
||||||
osabi = concat (osabi, "|", osabis[i].name, NULL);
|
|
||||||
|
|
||||||
fprintf (stream, _("Usage: %s <option(s)> elffile(s)\n"),
|
fprintf (stream, _("Usage: %s <option(s)> elffile(s)\n"),
|
||||||
program_name);
|
program_name);
|
||||||
|
|||||||
Reference in New Issue
Block a user