This is the mail archive of the
gdb-patches@sourceware.org
mailing list for the GDB project.
[PATCH c++ 5/5] mips: Add cast for int to enum conversion
- From: Simon Marchi <simon dot marchi at polymtl dot ca>
- To: gdb-patches at sourceware dot org
- Cc: Simon Marchi <simon dot marchi at polymtl dot ca>
- Date: Sun, 11 Oct 2015 00:37:18 -0400
- Subject: [PATCH c++ 5/5] mips: Add cast for int to enum conversion
- Authentication-results: sourceware.org; auth=none
- References: <1444538238-7468-1-git-send-email-simon dot marchi at polymtl dot ca>
This patch is taken directly from Pedro's branch.
/home/pedro/gdb/mygit/src/gdb/mips-tdep.c: In function âULONGEST mips_fetch_instruction(gdbarch*, mips_isa, CORE_ADDR, int*)â:
/home/pedro/gdb/mygit/src/gdb/mips-tdep.c:1460:28: error: invalid conversion from âintâ to âtarget_xfer_statusâ [-fpermissive]
memory_error (status, addr);
gdb/ChangeLog:
* mips-tdep.c (mips_fetch_instruction): Add cast.
---
gdb/mips-tdep.c | 2 +-
1 file changed, 1 insertion(+), 1 deletion(-)
diff --git a/gdb/mips-tdep.c b/gdb/mips-tdep.c
index 2275138..73b9221 100644
--- a/gdb/mips-tdep.c
+++ b/gdb/mips-tdep.c
@@ -1456,7 +1456,7 @@ mips_fetch_instruction (struct gdbarch *gdbarch,
if (status)
{
if (statusp == NULL)
- memory_error (status, addr);
+ memory_error ((enum target_xfer_status) status, addr);
return 0;
}
return extract_unsigned_integer (buf, instlen, byte_order);
--
2.6.1