aboutsummaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authorSimon Marchi <simon.marchi@polymtl.ca>2015-10-29 13:41:14 -0400
committerSimon Marchi <simon.marchi@ericsson.com>2015-10-29 13:43:02 -0400
commitcb0a2700865a77a111994ced22fd68815e5eed63 (patch)
treeb148e0286105fbfe33fa83ec9bd76e1115fc3bc6
parent15cf126c04a3720fb856f7f3bfb56869d5855939 (diff)
downloadgdb-cb0a2700865a77a111994ced22fd68815e5eed63.zip
gdb-cb0a2700865a77a111994ced22fd68815e5eed63.tar.gz
gdb-cb0a2700865a77a111994ced22fd68815e5eed63.tar.bz2
Add a cast in jit_target_read_impl
We could change the signature of the function. However, it would require changing gdb_target_read in jit-reader.h, which is an exported interface. It's probably better to just add a cast in our code than to break other people's code. gdb/ChangeLog: * jit.c (jit_target_read_impl): Add cast.
-rw-r--r--gdb/ChangeLog4
-rw-r--r--gdb/jit.c3
2 files changed, 6 insertions, 1 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index 8b79abb..78100fa 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,9 @@
2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
+ * jit.c (jit_target_read_impl): Add cast.
+
+2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
+
* jit.c (jit_reader_load): Add cast.
2015-10-29 Simon Marchi <simon.marchi@polymtl.ca>
diff --git a/gdb/jit.c b/gdb/jit.c
index ddc223d..7c6aede 100644
--- a/gdb/jit.c
+++ b/gdb/jit.c
@@ -491,7 +491,8 @@ typedef CORE_ADDR jit_dbg_reader_data;
static enum gdb_status
jit_target_read_impl (GDB_CORE_ADDR target_mem, void *gdb_buf, int len)
{
- int result = target_read_memory ((CORE_ADDR) target_mem, gdb_buf, len);
+ int result = target_read_memory ((CORE_ADDR) target_mem,
+ (gdb_byte *) gdb_buf, len);
if (result == 0)
return GDB_SUCCESS;
else