Fix: flt.lttng-utils.debug-info: ".debug" extension not appended
authorFrancis Deslauriers <francis.deslauriers@efficios.com>
Wed, 24 Apr 2019 14:54:31 +0000 (10:54 -0400)
committerPhilippe Proulx <eeppeliteloop@gmail.com>
Thu, 2 May 2019 04:09:19 +0000 (00:09 -0400)
commit80d8b94880bfeb55efb4f71ca205a6dfb489d1aa
tree0168e07983ec8481a89edc6c7e478e2a25b5e977
parent44fa6151e730c84e5a65a09fca6830b4ba8b24c2
Fix: flt.lttng-utils.debug-info: ".debug" extension not appended

Issue
=====
The g_strconcat() function returns a newly allocated string and does not
change the string in place as the code seems to assume. This results in
the call to g_strconcat() having no effects. Because of this, the
".debug" extension is not appended to the file name resulting in a
failure find the file on the file system.

Ignoring the return value of this call also results in the leaking of
the resulting char array.

Solution
========
Use g_snprintf() instead to concatenate the file name and its extension.

Known drawbacks
===============
None.

Signed-off-by: Francis Deslauriers <francis.deslauriers@efficios.com>
plugins/lttng-utils/debug-info/bin-info.c
This page took 0.023304 seconds and 5 git commands to generate.