From mboxrd@z Thu Jan 1 00:00:00 1970 Return-Path: Received: (qmail 21743 invoked by alias); 14 Dec 2004 20:01:08 -0000 Mailing-List: contact gdb-patches-help@sources.redhat.com; run by ezmlm Precedence: bulk List-Subscribe: List-Archive: List-Post: List-Help: , Sender: gdb-patches-owner@sources.redhat.com Received: (qmail 21641 invoked from network); 14 Dec 2004 20:00:43 -0000 Received: from unknown (HELO mx1.redhat.com) (66.187.233.31) by sourceware.org with SMTP; 14 Dec 2004 20:00:43 -0000 Received: from int-mx1.corp.redhat.com (int-mx1.corp.redhat.com [172.16.52.254]) by mx1.redhat.com (8.12.11/8.12.11) with ESMTP id iBEK0cP2012826 for ; Tue, 14 Dec 2004 15:00:43 -0500 Received: from pobox.corp.redhat.com (pobox.corp.redhat.com [172.16.52.156]) by int-mx1.corp.redhat.com (8.11.6/8.11.6) with ESMTP id iBEK0Wr10414 for ; Tue, 14 Dec 2004 15:00:32 -0500 Received: from localhost.localdomain (vpn50-35.rdu.redhat.com [172.16.50.35]) by pobox.corp.redhat.com (8.12.8/8.12.8) with ESMTP id iBEK0Wbo027876; Tue, 14 Dec 2004 15:00:32 -0500 Received: from ironwood.lan (ironwood.lan [192.168.64.8]) by localhost.localdomain (8.12.11/8.12.10) with ESMTP id iBEK0Q6G013654; Tue, 14 Dec 2004 13:00:27 -0700 Date: Tue, 14 Dec 2004 22:47:00 -0000 From: Kevin Buettner To: gdb-patches@sources.redhat.com Cc: Corinna Vinschen Subject: [RFA] xstormy16-tdep.c: Initialize temporary frame cache in xstormy16_skip_prologue() Message-ID: <20041214130026.7536057c@ironwood.lan> Organization: Red Hat Mime-Version: 1.0 Content-Type: text/plain; charset=US-ASCII Content-Transfer-Encoding: 7bit X-SW-Source: 2004-12/txt/msg00374.txt.bz2 [Corinna requested that I resend this patch...] The patch below clears the frame cache for the call to xstormy16_analyze_prologue(). If this initialization is not performed, then the ``if (!cache.uses_fp)'' test following the call in question will reference an uninitialized value. Okay? * xstormy16-tdep.c (xstormy16_skip_prologue): Clear/initialize the frame cache. Index: xstormy16-tdep.c =================================================================== RCS file: /cvs/src/src/gdb/xstormy16-tdep.c,v retrieving revision 1.84 diff -u -p -r1.84 xstormy16-tdep.c --- xstormy16-tdep.c 31 Oct 2004 20:36:34 -0000 1.84 +++ xstormy16-tdep.c 29 Nov 2004 21:25:19 -0000 @@ -414,6 +414,8 @@ xstormy16_skip_prologue (CORE_ADDR pc) struct symbol *sym; struct xstormy16_frame_cache cache; + memset (&cache, 0, sizeof cache); + /* Don't trust line number debug info in frameless functions. */ CORE_ADDR plg_end = xstormy16_analyze_prologue (func_addr, func_end, &cache, NULL);