libctf: Pass format argument to asprintf

libctf/ChangeLog
2020-09-23  H.J. Lu  <hongjiu.lu@intel.com>

	PR libctf/26934
	* ctf-dump.c (ctf_dump_objts): Pass format argument to asprintf.
This commit is contained in:
H.J. Lu 2020-11-24 14:08:43 +00:00 committed by Nick Alcock
parent 96c61be508
commit e8cda20905
2 changed files with 6 additions and 1 deletions

View File

@ -1,3 +1,8 @@
2020-09-23 H.J. Lu <hongjiu.lu@intel.com>
PR libctf/26934
* ctf-dump.c (ctf_dump_objts): Pass format argument to asprintf.
2020-11-23 Nick Alcock <nick.alcock@oracle.com>
* ctf-impl.h (ctf_dict_t) <ctf_symtab_little_endian>: New.

View File

@ -403,7 +403,7 @@ ctf_dump_objts (ctf_dict_t *fp, ctf_dump_state_t *state, int functions)
goto out;
}
if (asprintf (&typestr, ctf_errmsg (ctf_errno (fp))) < 0)
if (asprintf (&typestr, _("error: %s"), ctf_errmsg (ctf_errno (fp))) < 0)
goto oom;
err = -1;