From owner-svn-src-all@FreeBSD.ORG Tue Nov 2 01:24:50 2010 Return-Path: Delivered-To: svn-src-all@freebsd.org Received: from mx1.freebsd.org (mx1.freebsd.org [IPv6:2001:4f8:fff6::34]) by hub.freebsd.org (Postfix) with ESMTP id 54F5E1065672; Tue, 2 Nov 2010 01:24:50 +0000 (UTC) (envelope-from gonzo@FreeBSD.org) Received: from svn.freebsd.org (svn.freebsd.org [IPv6:2001:4f8:fff6::2c]) by mx1.freebsd.org (Postfix) with ESMTP id 4315C8FC16; Tue, 2 Nov 2010 01:24:50 +0000 (UTC) Received: from svn.freebsd.org (localhost [127.0.0.1]) by svn.freebsd.org (8.14.3/8.14.3) with ESMTP id oA21OoVD003614; Tue, 2 Nov 2010 01:24:50 GMT (envelope-from gonzo@svn.freebsd.org) Received: (from gonzo@localhost) by svn.freebsd.org (8.14.3/8.14.3/Submit) id oA21OoXf003612; Tue, 2 Nov 2010 01:24:50 GMT (envelope-from gonzo@svn.freebsd.org) Message-Id: <201011020124.oA21OoXf003612@svn.freebsd.org> From: Oleksandr Tymoshenko Date: Tue, 2 Nov 2010 01:24:50 +0000 (UTC) To: src-committers@freebsd.org, svn-src-all@freebsd.org, svn-src-head@freebsd.org X-SVN-Group: head MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit Cc: Subject: svn commit: r214651 - head/contrib/gdb/gdb X-BeenThere: svn-src-all@freebsd.org X-Mailman-Version: 2.1.5 Precedence: list List-Id: "SVN commit messages for the entire src tree \(except for " user" and " projects" \)" List-Unsubscribe: , List-Archive: List-Post: List-Help: List-Subscribe: , X-List-Received-Date: Tue, 02 Nov 2010 01:24:50 -0000 Author: gonzo Date: Tue Nov 2 01:24:49 2010 New Revision: 214651 URL: http://svn.freebsd.org/changeset/base/214651 Log: Fix reading of .debug_line on MIPS64, big-endian: read_initial_length detects pointer size by checking first 4 bytes of .debug_line and stores it in struct comp_unit_head * passed to it as second argument. By passing NULL to a read_initial_length we ignore actual pointer size (8 bytes) and use default (4 bytes) which results in wrong offsets of header fields. Modified: head/contrib/gdb/gdb/dwarf2read.c Modified: head/contrib/gdb/gdb/dwarf2read.c ============================================================================== --- head/contrib/gdb/gdb/dwarf2read.c Mon Nov 1 22:11:18 2010 (r214650) +++ head/contrib/gdb/gdb/dwarf2read.c Tue Nov 2 01:24:49 2010 (r214651) @@ -5178,7 +5178,7 @@ dwarf_decode_line_header (unsigned int o line_ptr = dwarf_line_buffer + offset; /* read in the header */ - lh->total_length = read_initial_length (abfd, line_ptr, NULL, &bytes_read); + lh->total_length = read_initial_length (abfd, line_ptr, &cu->header, &bytes_read); line_ptr += bytes_read; if (line_ptr + lh->total_length > dwarf_line_buffer + dwarf_line_size) {