* dwarf2out.c (dwarf2out_var_location): Do not pass NULL to fprintf.

From-SVN: r256454
This commit is contained in:
Eric Botcazou 2018-01-10 20:59:04 +00:00 committed by Eric Botcazou
parent 2025a48d08
commit 88324fd006
2 changed files with 11 additions and 2 deletions

View File

@ -1,3 +1,7 @@
2018-01-10 Eric Botcazou <ebotcazou@adacore.com>
* dwarf2out.c (dwarf2out_var_location): Do not pass NULL to fprintf.
2018-01-10 Peter Bergner <bergner@vnet.ibm.com>
PR target/83399

View File

@ -26584,11 +26584,16 @@ create_label:
if (var_loc_p && flag_debug_asm)
{
const char *name = NULL, *sep = " => ", *patstr = NULL;
const char *name, *sep, *patstr;
if (decl && DECL_NAME (decl))
name = IDENTIFIER_POINTER (DECL_NAME (decl));
else
name = "";
if (NOTE_VAR_LOCATION_LOC (loc_note))
patstr = str_pattern_slim (NOTE_VAR_LOCATION_LOC (loc_note));
{
sep = " => ";
patstr = str_pattern_slim (NOTE_VAR_LOCATION_LOC (loc_note));
}
else
{
sep = " ";