This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
[PATCH] Minor sh-tdep.c fix
- From: Elena Zannoni <ezannoni at redhat dot com>
- To: gdb-patches at sources dot redhat dot com
- Date: Sun, 7 Apr 2002 18:13:05 -0400
- Subject: [PATCH] Minor sh-tdep.c fix
I just committed this.
Elena
2002-04-07 Elena Zannoni <ezannoni@redhat.com>
* sh-tdep.c (sh_fp_frame_init_saved_regs,
sh_nofp_frame_init_saved_regs): Use alloca() for 'where'
information.
Index: sh-tdep.c
===================================================================
RCS file: /cvs/uberbaum/gdb/sh-tdep.c,v
retrieving revision 1.50
diff -u -p -r1.50 sh-tdep.c
--- sh-tdep.c 6 Apr 2002 00:02:50 -0000 1.50
+++ sh-tdep.c 7 Apr 2002 22:10:22 -0000
@@ -481,7 +481,7 @@ sh_find_callers_reg (struct frame_info *
static void
sh_nofp_frame_init_saved_regs (struct frame_info *fi)
{
- int where[NUM_REGS + NUM_PSEUDO_REGS];
+ int *where = (int *) alloca (NUM_REGS + NUM_PSEUDO_REGS);
int rn;
int have_fp = 0;
int depth;
@@ -623,7 +623,7 @@ dr_reg_base_num (int dr_regnum)
static void
sh_fp_frame_init_saved_regs (struct frame_info *fi)
{
- int where[NUM_REGS + NUM_PSEUDO_REGS];
+ int *where = (int *) alloca (NUM_REGS + NUM_PSEUDO_REGS);
int rn;
int have_fp = 0;
int depth;