From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 6208 invoked by alias); 8 Mar 2012 14:31:08 -0000 Received: (qmail 6192 invoked by uid 22791); 8 Mar 2012 14:31:06 -0000 X-SWARE-Spam-Status: No, hits=0.8 required=5.0 tests=AWL,BAYES_00,KAM_STOCKTIP,TW_BJ,T_RP_MATCHES_RCVD X-Spam-Check-By: sourceware.org Received: from mail.allinea.com (HELO mail.allinea.com) (94.125.131.200) by sourceware.org (qpsmtpd/0.43rc1) with ESMTP; Thu, 08 Mar 2012 14:30:54 +0000 Received: from localhost (localhost [127.0.0.1]) by mail.allinea.com (Postfix) with ESMTP id 5F85112FBFE for ; Thu, 8 Mar 2012 14:30:53 +0000 (GMT) Received: from mail.allinea.com ([127.0.0.1]) by localhost (mail.allinea.com [127.0.0.1]) (amavisd-new, port 10024) with ESMTP id LVpd3fV4hOVo for ; Thu, 8 Mar 2012 14:30:53 +0000 (GMT) Received: from [192.168.0.6] (cpc11-sotn9-2-0-cust158.15-1.cable.virginmedia.com [81.101.103.159]) (Authenticated sender: cjanuary) by mail.allinea.com (Postfix) with ESMTPSA id F133312FBFC for ; Thu, 8 Mar 2012 14:30:52 +0000 (GMT) Message-ID: <1331217052.2742.12.camel@gumtree> Subject: [PATCH] Support Fortran common blocks with addresses >INT_MAX. From: Chris January To: gdb-patches@sourceware.org Date: Thu, 08 Mar 2012 14:31:00 -0000 Content-Type: text/plain; charset="UTF-8" Content-Transfer-Encoding: 7bit Mime-Version: 1.0 X-IsSubscribed: yes Mailing-List: contact gdb-patches-help@sourceware.org; run by ezmlm Precedence: bulk List-Id: List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sourceware.org X-SW-Source: 2012-03/txt/msg00266.txt.bz2 The address of a Fortran common block may be >INT_MAX. fix_common_block should be using CORE_ADDR, not int. 2012-03-08 Chris January * stabsread.c (fix_common_block): Change type of valu argument to CORE_ADDR. --- Index: gdb/stabsread.c =================================================================== --- gdb/stabsread.c.orig 2011-02-17 11:14:42.713081030 +0000 +++ gdb/stabsread.c 2011-02-17 11:15:14.414327296 +0000 @@ -104,7 +104,7 @@ static void patch_block_stabs (struct pending *, struct pending_stabs *, struct objfile *); -static void fix_common_block (struct symbol *, int); +static void fix_common_block (struct symbol *, CORE_ADDR); static int read_type_number (char **, int *); @@ -4805,7 +4805,7 @@ common_block_end (struct objfile *objfil the common block name). */ static void -fix_common_block (struct symbol *sym, int valu) +fix_common_block (struct symbol *sym, CORE_ADDR valu) { struct pending *next = (struct pending *) SYMBOL_TYPE (sym);