2
1

0001-Remove-const-in-xtensa-linux-nat.c-fetch_gregs.patch 1.2 KB

123456789101112131415161718192021222324252627282930313233343536373839
  1. From d274ecf4ddf76768af57e27f654b9ce6784b391c Mon Sep 17 00:00:00 2001
  2. From: Simon Marchi <simon.marchi@ericsson.com>
  3. Date: Mon, 6 Mar 2017 16:06:42 -0500
  4. Subject: [PATCH] Remove const in xtensa-linux-nat.c:fetch_gregs
  5. Fixes:
  6. /home/emaisin/src/binutils-gdb/gdb/xtensa-linux-nat.c: In function 'void fetch_gregs(regcache*, ptid_t, int)':
  7. /home/emaisin/src/binutils-gdb/gdb/xtensa-linux-nat.c:178:23: error: uninitialized const 'regs' [-fpermissive]
  8. const gdb_gregset_t regs;
  9. ^
  10. gdb/ChangeLog:
  11. * xtensa-linux-nat.c (fetch_gregs): Remove const.
  12. Signed-off-by: Max Filippov <jcmvbkbc@gmail.com>
  13. ---
  14. Backported from: d274ecf4ddf76768af57e27f654b9ce6784b391c
  15. gdb/xtensa-linux-nat.c | 2 +-
  16. 1 file changed, 1 insertion(+), 1 deletion(-)
  17. diff --git a/gdb/xtensa-linux-nat.c b/gdb/xtensa-linux-nat.c
  18. index afe15f6..c29f0c7 100644
  19. --- a/gdb/xtensa-linux-nat.c
  20. +++ b/gdb/xtensa-linux-nat.c
  21. @@ -175,7 +175,7 @@ static void
  22. fetch_gregs (struct regcache *regcache, int regnum)
  23. {
  24. int tid = ptid_get_lwp (inferior_ptid);
  25. - const gdb_gregset_t regs;
  26. + gdb_gregset_t regs;
  27. int areg;
  28. if (ptrace (PTRACE_GETREGS, tid, 0, (long) &regs) < 0)
  29. --
  30. 2.1.4