/* SPU native-dependent code for GDB, the GNU debugger.
- Copyright (C) 2006-2015 Free Software Foundation, Inc.
+ Copyright (C) 2006-2016 Free Software Foundation, Inc.
Contributed by Ulrich Weigand <uweigand@de.ibm.com>.
{
ULONGEST addr = *(ULONGEST *)stream;
- if (fetch_ppc_memory (addr + offset, buf, nbytes) != 0)
+ if (fetch_ppc_memory (addr + offset, (gdb_byte *)buf, nbytes) != 0)
{
bfd_set_error (bfd_error_invalid_operation);
return -1;
struct bfd *nbfd;
asection *spu_name;
- ULONGEST *open_closure = xmalloc (sizeof (ULONGEST));
+ ULONGEST *open_closure = XNEW (ULONGEST);
*open_closure = addr;
nbfd = gdb_bfd_openr_iovec ("<in-memory>", "elf32-spu",
int sect_size = bfd_section_size (nbfd, spu_name);
if (sect_size > 20)
{
- char *buf = alloca (sect_size - 20 + 1);
+ char *buf = (char *)alloca (sect_size - 20 + 1);
bfd_get_section_contents (nbfd, spu_name, buf, 20, sect_size - 20);
buf[sect_size - 20] = '\0';