From bbc212e1244dbd30c2569cdd19d50ca36ca6612a Mon Sep 17 00:00:00 2001 From: Wenji Huang Date: Thu, 17 Sep 2009 14:25:28 +0800 Subject: Fix compilation error of dwflpp.cxx on gcc 4.1 * dwflpp.cxx(translate_location): Separate setting value from declaration and add missing parameter. --- dwflpp.cxx | 5 +++-- 1 file changed, 3 insertions(+), 2 deletions(-) (limited to 'dwflpp.cxx') diff --git a/dwflpp.cxx b/dwflpp.cxx index a73c3c4c..ee3985cb 100644 --- a/dwflpp.cxx +++ b/dwflpp.cxx @@ -1732,11 +1732,12 @@ dwflpp::translate_location(struct obstack *pool, #if !_ELFUTILS_PREREQ (0,142) if (dwarf_whatattr (attr) == DW_AT_data_member_location) { - Dwarf_Op offset_loc = { .atom = DW_OP_plus_uconst }; + Dwarf_Op offset_loc; + offset_loc.atom = DW_OP_plus_uconst; if (dwarf_formudata (attr, &offset_loc.number) == 0) return c_translate_location (pool, &loc2c_error, this, &loc2c_emit_address, 1, 0, pc, - &offset_loc, 1, NULL, NULL); + &offset_loc, 1, NULL, NULL, NULL); } #endif -- cgit