diff options
author | Aleksandar Ristovski <aristovski@qnx.com> | 2008-07-23 13:36:00 +0000 |
---|---|---|
committer | Aleksandar Ristovski <aristovski@qnx.com> | 2008-07-23 13:36:00 +0000 |
commit | 4b38776427c28ad0c615c05763d259bebf855ded (patch) | |
tree | cf004ab719912b8a82272b26610f622ac1948f19 | |
parent | cb12d8accf51352294f675e3a639ae00e84f7ca8 (diff) | |
download | gdb-4b38776427c28ad0c615c05763d259bebf855ded.tar.gz |
* nto-procfs.c (procfs_xfer_memory): Changed signature.
(procfs_resume): Workaround for dereferencing type-punned pointer
warning.
* nto-tdep.c (nto_parse_redirection): Change signature to be const
correct.
* nto-tdep.h (nto_parse_redirection): Likewise.
-rw-r--r-- | gdb/ChangeLog | 9 | ||||
-rw-r--r-- | gdb/nto-procfs.c | 25 | ||||
-rw-r--r-- | gdb/nto-tdep.c | 3 | ||||
-rw-r--r-- | gdb/nto-tdep.h | 4 |
4 files changed, 26 insertions, 15 deletions
diff --git a/gdb/ChangeLog b/gdb/ChangeLog index 6b6d20c7e2a..02d12633faf 100644 --- a/gdb/ChangeLog +++ b/gdb/ChangeLog @@ -1,3 +1,12 @@ +2008-07-23 Aleksandar Ristovski <aristovski@qnx.com> + + * nto-procfs.c (procfs_xfer_memory): Changed signature. + (procfs_resume): Workaround for dereferencing type-punned pointer + warning. + * nto-tdep.c (nto_parse_redirection): Change signature to be const + correct. + * nto-tdep.h (nto_parse_redirection): Likewise. + 2008-07-21 Stan Shebs <stan@codesourcery.com> Scrub remnants of IN_SOLIB_DYNSYM_RESOLVE_CODE. diff --git a/gdb/nto-procfs.c b/gdb/nto-procfs.c index e37e1581330..2ef6e0f6a78 100644 --- a/gdb/nto-procfs.c +++ b/gdb/nto-procfs.c @@ -61,7 +61,7 @@ static int procfs_can_run (void); static ptid_t procfs_wait (ptid_t, struct target_waitstatus *); -static int procfs_xfer_memory (CORE_ADDR, char *, int, int, +static int procfs_xfer_memory (CORE_ADDR, gdb_byte *, int, int, struct mem_attrib *attrib, struct target_ops *); @@ -744,7 +744,7 @@ procfs_fetch_registers (struct regcache *regcache, int regno) doesn't allow memory operations to cross below us in the target stack anyway. */ static int -procfs_xfer_memory (CORE_ADDR memaddr, char *myaddr, int len, int dowrite, +procfs_xfer_memory (CORE_ADDR memaddr, gdb_byte *myaddr, int len, int dowrite, struct mem_attrib *attrib, struct target_ops *target) { int nbytes = 0; @@ -838,6 +838,7 @@ procfs_resume (ptid_t ptid, int step, enum target_signal signo) { int signal_to_pass; procfs_status status; + sigset_t *run_fault = (sigset_t *) (void *) &run.fault; if (ptid_equal (inferior_ptid, null_ptid)) return; @@ -849,17 +850,17 @@ procfs_resume (ptid_t ptid, int step, enum target_signal signo) if (step) run.flags |= _DEBUG_RUN_STEP; - sigemptyset ((sigset_t *) &run.fault); - sigaddset ((sigset_t *) &run.fault, FLTBPT); - sigaddset ((sigset_t *) &run.fault, FLTTRACE); - sigaddset ((sigset_t *) &run.fault, FLTILL); - sigaddset ((sigset_t *) &run.fault, FLTPRIV); - sigaddset ((sigset_t *) &run.fault, FLTBOUNDS); - sigaddset ((sigset_t *) &run.fault, FLTIOVF); - sigaddset ((sigset_t *) &run.fault, FLTIZDIV); - sigaddset ((sigset_t *) &run.fault, FLTFPE); + sigemptyset (run_fault); + sigaddset (run_fault, FLTBPT); + sigaddset (run_fault, FLTTRACE); + sigaddset (run_fault, FLTILL); + sigaddset (run_fault, FLTPRIV); + sigaddset (run_fault, FLTBOUNDS); + sigaddset (run_fault, FLTIOVF); + sigaddset (run_fault, FLTIZDIV); + sigaddset (run_fault, FLTFPE); /* Peter V will be changing this at some point. */ - sigaddset ((sigset_t *) &run.fault, FLTPAGE); + sigaddset (run_fault, FLTPAGE); run.flags |= _DEBUG_RUN_ARM; diff --git a/gdb/nto-tdep.c b/gdb/nto-tdep.c index 9abd28ccf22..c9a02df9e13 100644 --- a/gdb/nto-tdep.c +++ b/gdb/nto-tdep.c @@ -196,7 +196,8 @@ nto_init_solib_absolute_prefix (void) } char ** -nto_parse_redirection (char *pargv[], char **pin, char **pout, char **perr) +nto_parse_redirection (char *pargv[], const char **pin, const char **pout, + const char **perr) { char **argv; char *in, *out, *err, *p; diff --git a/gdb/nto-tdep.h b/gdb/nto-tdep.h index 6db2b064973..30be3c54857 100644 --- a/gdb/nto-tdep.h +++ b/gdb/nto-tdep.h @@ -144,8 +144,8 @@ void nto_init_solib_absolute_prefix (void); void nto_set_target(struct nto_target_ops *); -char **nto_parse_redirection (char *start_argv[], char **in, - char **out, char **err); +char **nto_parse_redirection (char *start_argv[], const char **in, + const char **out, const char **err); int proc_iterate_over_mappings (int (*func) (int, CORE_ADDR)); |