From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 29384 invoked by alias); 20 Jan 2014 03:41:18 -0000 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 Received: (qmail 29375 invoked by uid 89); 20 Jan 2014 03:41:18 -0000 Authentication-Results: sourceware.org; auth=none X-Virus-Found: No X-Spam-SWARE-Status: No, score=-2.4 required=5.0 tests=BAYES_00,FREEMAIL_ENVFROM_END_DIGIT,FREEMAIL_FROM,RCVD_IN_DNSWL_LOW,SPF_PASS autolearn=ham version=3.3.2 X-HELO: mail-pa0-f50.google.com Received: from mail-pa0-f50.google.com (HELO mail-pa0-f50.google.com) (209.85.220.50) by sourceware.org (qpsmtpd/0.93/v0.84-503-g423c35a) with (AES128-SHA encrypted) ESMTPS; Mon, 20 Jan 2014 03:41:17 +0000 Received: by mail-pa0-f50.google.com with SMTP id kp14so6500307pab.9 for ; Sun, 19 Jan 2014 19:41:15 -0800 (PST) X-Received: by 10.68.164.131 with SMTP id yq3mr16304587pbb.56.1390189275628; Sun, 19 Jan 2014 19:41:15 -0800 (PST) Received: from ubuntu.dhcp.ucweb.local ([70.39.187.196]) by mx.google.com with ESMTPSA id om6sm40475560pbc.43.2014.01.19.19.41.13 for (version=TLSv1.1 cipher=ECDHE-RSA-RC4-SHA bits=128/128); Sun, 19 Jan 2014 19:41:15 -0800 (PST) From: manjian2006@gmail.com To: gdb-patches@sourceware.org Cc: manjian2006 Subject: [PATCH] fixed inherit_abstract_dies infinite recursive call Date: Mon, 20 Jan 2014 03:41:00 -0000 Message-Id: <1390189261-32115-1-git-send-email-manjian2006@gmail.com> X-SW-Source: 2014-01/txt/msg00728.txt.bz2 From: manjian2006 --- gdb/dwarf2read.c | 7 +++++++ 1 file changed, 7 insertions(+) diff --git a/gdb/dwarf2read.c b/gdb/dwarf2read.c index 7ca527d..4532251 100644 --- a/gdb/dwarf2read.c +++ b/gdb/dwarf2read.c @@ -1224,6 +1224,8 @@ struct die_info /* True if we're presently building the full type name for the type derived from this DIE. */ unsigned char building_fullname : 1; + /* True if this die is in process */ + unsigned char in_process : 1; /* Abbrev number */ unsigned int abbrev; @@ -8013,6 +8015,10 @@ process_imported_unit_die (struct die_info *die, struct dwarf2_cu *cu) static void process_die (struct die_info *die, struct dwarf2_cu *cu) { + /* Only process those who are not in process */ + if(die->in_process) + return; + die->in_process = 1; switch (die->tag) { case DW_TAG_padding: @@ -8100,6 +8106,7 @@ process_die (struct die_info *die, struct dwarf2_cu *cu) new_symbol (die, NULL, cu); break; } + die->in_process = 0; } /* DWARF name computation. */ -- 1.8.3.2