+2000-08-09 Michael Snyder <msnyder@cleaver.cygnus.com>
+
+ * blockframe.c (sigtramp_saved_pc): Use dynamic allocation,
+ since TARGET_PTR_BIT is no longer a constant (MULTI_ARCH).
+ * irix4-nat.c (get_longjmp_target): Ditto.
+ * irix5-nat.c (get_longjmp_target): Ditto.
+ * jv-valprint.c (java_value_print): Ditto.
+ * m3-nat.c (get_cprocs): Ditto.
+ * m68k-tdep.c (get_longjmp_target): Ditto.
+ * mips-nat.c (get_longjmp_target): Ditto.
+ * mipsv4-nat.c(get_longjmp_target): Ditto.
+ * pa64solib.c (read_dynamic_info): Ditto.
+ * solib.c (elf_locate_base): Ditto.
+
Mon Aug 7 23:21:22 2000 David Taylor <taylor@texas.cygnus.com>
* TODO: remove build_parse entry.
sigtramp_saved_pc (struct frame_info *frame)
{
CORE_ADDR sigcontext_addr;
- char buf[TARGET_PTR_BIT / TARGET_CHAR_BIT];
+ char *buf;
int ptrbytes = TARGET_PTR_BIT / TARGET_CHAR_BIT;
int sigcontext_offs = (2 * TARGET_INT_BIT) / TARGET_CHAR_BIT;
+ buf = alloca (ptrbytes);
/* Get sigcontext address, it is the third parameter on the stack. */
if (frame->next)
sigcontext_addr = read_memory_integer (FRAME_ARGS_ADDRESS (frame->next)
int
get_longjmp_target (CORE_ADDR *pc)
{
- char buf[TARGET_PTR_BIT / TARGET_CHAR_BIT];
+ char *buf;
CORE_ADDR jb_addr;
+ buf = alloca (TARGET_PTR_BIT / TARGET_CHAR_BIT);
jb_addr = read_register (A0_REGNUM);
if (target_read_memory (jb_addr + JB_PC * JB_ELEMENT_SIZE, buf,
int
get_longjmp_target (CORE_ADDR *pc)
{
- char buf[TARGET_PTR_BIT / TARGET_CHAR_BIT];
+ char *buf;
CORE_ADDR jb_addr;
+ buf = alloca (TARGET_PTR_BIT / TARGET_CHAR_BIT);
jb_addr = read_register (A0_REGNUM);
if (target_read_memory (jb_addr + JB_PC * JB_ELEMENT_SIZE, buf,
while (i < length && things_printed < print_max)
{
- char buf[TARGET_PTR_BIT / HOST_CHAR_BIT];
+ char *buf;
+ buf = alloca (TARGET_PTR_BIT / HOST_CHAR_BIT);
fputs_filtered (", ", stream);
wrap_here (n_spaces (2));
gdb_thread_t cproc_head;
gdb_thread_t cproc_copy;
CORE_ADDR their_cprocs;
- char *buf[TARGET_PTR_BIT / HOST_CHAR_BIT];
+ char *buf;
char *name;
cthread_t cthread;
CORE_ADDR symaddr;
+ buf = alloca (TARGET_PTR_BIT / HOST_CHAR_BIT);
symaddr = lookup_address_of_variable ("cproc_list");
if (!symaddr)
int
get_longjmp_target (CORE_ADDR *pc)
{
- char buf[TARGET_PTR_BIT / TARGET_CHAR_BIT];
+ char *buf;
CORE_ADDR sp, jb_addr;
+ buf = alloca (TARGET_PTR_BIT / TARGET_CHAR_BIT);
sp = read_register (SP_REGNUM);
if (target_read_memory (sp + SP_ARG0, /* Offset of first arg on stack */
get_longjmp_target (CORE_ADDR *pc)
{
CORE_ADDR jb_addr;
- char buf[TARGET_PTR_BIT / TARGET_CHAR_BIT];
+ char *buf;
+ buf = alloca (TARGET_PTR_BIT / TARGET_CHAR_BIT);
jb_addr = read_register (A0_REGNUM);
if (target_read_memory (jb_addr + JB_PC * JB_ELEMENT_SIZE, buf,
int
get_longjmp_target (CORE_ADDR *pc)
{
- char buf[TARGET_PTR_BIT / TARGET_CHAR_BIT];
+ char *buf;
CORE_ADDR jb_addr;
+ buf = alloca (TARGET_PTR_BIT / TARGET_CHAR_BIT);
jb_addr = read_register (A0_REGNUM);
if (target_read_memory (jb_addr + _JB_PC * JB_ELEMENT_SIZE, buf,
Elf64_Dyn *x_dynp = (Elf64_Dyn*)buf;
Elf64_Sxword dyn_tag;
CORE_ADDR dyn_ptr;
- char pbuf[TARGET_PTR_BIT / HOST_CHAR_BIT];
+ char *pbuf;
+ pbuf = alloca (TARGET_PTR_BIT / HOST_CHAR_BIT);
dyn_tag = bfd_h_get_64 (symfile_objfile->obfd,
(bfd_byte*) &x_dynp->d_tag);
#ifdef DT_MIPS_RLD_MAP
else if (dyn_tag == DT_MIPS_RLD_MAP)
{
- char pbuf[TARGET_PTR_BIT / HOST_CHAR_BIT];
+ char *pbuf;
+ pbuf = alloca (TARGET_PTR_BIT / HOST_CHAR_BIT);
/* DT_MIPS_RLD_MAP contains a pointer to the address
of the dynamic link structure. */
dyn_ptr = bfd_h_get_32 (exec_bfd,