From: Petr Machata Date: Mon, 23 Nov 2009 12:32:32 +0000 (+0100) Subject: dwarflint: Fix relocating of abbrev table offset in CU header loader X-Git-Url: http://git.ipfire.org/gitweb.cgi?a=commitdiff_plain;h=d516d8563e9eb0d5575d122ad4497d2879b0ff39;p=thirdparty%2Felfutils.git dwarflint: Fix relocating of abbrev table offset in CU header loader --- diff --git a/src/dwarflint/check_debug_info.cc b/src/dwarflint/check_debug_info.cc index 85b927b6f..cf8c1b7fb 100644 --- a/src/dwarflint/check_debug_info.cc +++ b/src/dwarflint/check_debug_info.cc @@ -182,12 +182,12 @@ namespace wr_error (head.where) << "invalid 64-bit unit in DWARF 2 format.\n"; head.version = version; - /* Abbrev offset. */ - uint64_t ctx_offset = read_ctx_get_offset (&ctx) + head.offset; + /* Abbrev table offset. */ + uint64_t ctx_offset = read_ctx_get_offset (&ctx); if (!read_ctx_read_offset (&ctx, head.offset_size == 8, &head.abbrev_offset)) { - wr_error (head.where) << "can't read abbrev offset." << std::endl; + wr_error (head.where) << "can't read abbrev table offset." << std::endl; throw check_base::failed (); } @@ -202,7 +202,7 @@ namespace } else if (file->ehdr.e_type == ET_REL) wr_message (head.where, cat (mc_impact_2, mc_info, mc_reloc)) - << pri::lacks_relocation ("abbrev offset") << std::endl; + << pri::lacks_relocation ("abbrev table offset") << std::endl; /* Address size. */ if (!read_address_size (file, &ctx, &head.address_size, &head.where))