This is the mail archive of the gdb-patches@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]

Re: [RFC] confusing comment in memory_xfer_partial


Ah.  "Never mind."

On Tue, Aug 5, 2008 at 10:24 PM, Doug Evans <dje@google.com> wrote:
> Hi.  I don't understand this comment in memory_xfer_partial.
> The code has already checked for writing to read-only memory
> and reading from write-only memory.  And in this `else' clause
> we know readbuf is NULL.
> Can you elaborate on what the comment is about?
> Preserve who's const correctness?
>
> 2008-08-05  Doug Evans  <dje@google.com>
>
>        * target.c (memory_xfer_partial): Delete outdated comment.
>
> Index: target.c
> ===================================================================
> RCS file: /cvs/src/src/gdb/target.c,v
> retrieving revision 1.169
> diff -u -p -u -p -r1.169 target.c
> --- target.c    9 Jul 2008 22:42:42 -0000       1.169
> +++ target.c    6 Aug 2008 05:15:03 -0000
> @@ -1071,9 +1071,6 @@ memory_xfer_partial (struct target_ops *
>        res = dcache_xfer_memory (target_dcache, memaddr, readbuf,
>                                  reg_len, 0);
>       else
> -       /* FIXME drow/2006-08-09: If we're going to preserve const
> -          correctness dcache_xfer_memory should take readbuf and
> -          writebuf.  */
>        res = dcache_xfer_memory (target_dcache, memaddr,
>                                  (void *) writebuf,
>                                  reg_len, 1);
>
>


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