This is the mail archive of the gdb-cvs@sourceware.org mailing list for the GDB project.


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]
Other format: [Raw text]

[binutils-gdb] proc-service.c: Add (gdb_byte *) cast


https://sourceware.org/git/gitweb.cgi?p=binutils-gdb.git;h=49e66b4debebff088958077201eabab36df168f0

commit 49e66b4debebff088958077201eabab36df168f0
Author: Simon Marchi <simon.marchi@polymtl.ca>
Date:   Sat Oct 24 18:36:25 2015 -0400

    proc-service.c: Add (gdb_byte *) cast
    
    A cast here is necessary, just as it's necessary in ps_pdwrite just
    below.  The type of buf can't be changed, since it's fixed in the ps_pd*
    API.
    
    gdb/ChangeLog:
    
    	* proc-service.c (ps_pdread): Add cast.

Diff:
---
 gdb/ChangeLog      | 4 ++++
 gdb/proc-service.c | 2 +-
 2 files changed, 5 insertions(+), 1 deletion(-)

diff --git a/gdb/ChangeLog b/gdb/ChangeLog
index e86cbad..fae9d4d 100644
--- a/gdb/ChangeLog
+++ b/gdb/ChangeLog
@@ -1,5 +1,9 @@
 2015-10-24  Simon Marchi  <simon.marchi@polymtl.ca>
 
+	* proc-service.c (ps_pdread): Add cast.
+
+2015-10-24  Simon Marchi  <simon.marchi@polymtl.ca>
+
 	* sparc64-tdep.c (sparc64_store_arguments): Split assignment of
 	valbuf.
 
diff --git a/gdb/proc-service.c b/gdb/proc-service.c
index 484054a..d05aa85 100644
--- a/gdb/proc-service.c
+++ b/gdb/proc-service.c
@@ -140,7 +140,7 @@ ps_err_e
 ps_pdread (gdb_ps_prochandle_t ph, psaddr_t addr,
 	   gdb_ps_read_buf_t buf, gdb_ps_size_t size)
 {
-  return ps_xfer_memory (ph, addr, buf, size, 0);
+  return ps_xfer_memory (ph, addr, (gdb_byte *) buf, size, 0);
 }
 
 /* Write SIZE bytes from BUF into the target process PH at address ADDR.  */


Index Nav: [Date Index] [Subject Index] [Author Index] [Thread Index]
Message Nav: [Date Prev] [Date Next] [Thread Prev] [Thread Next]