2010-10-31 Hui Zhu <teawater@gmail.com>
authorHui Zhu <teawater@gmail.com>
Mon, 1 Nov 2010 07:00:13 +0000 (07:00 +0000)
committerHui Zhu <teawater@gmail.com>
Mon, 1 Nov 2010 07:00:13 +0000 (07:00 +0000)
* tracepoint.c (tfile_xfer_partial): Change lma to vma.

gdb/ChangeLog
gdb/tracepoint.c

index f8001b6b80832b3b39479f458fe162aea78a7fd0..b2c9650c5a844673ecfedac3a9460f770600abf5 100644 (file)
@@ -1,3 +1,7 @@
+2010-11-01  Hui Zhu  <teawater@gmail.com>
+
+       * tracepoint.c (tfile_xfer_partial): Change lma to vma.
+
 2010-10-28  Hui Zhu  <teawater@gmail.com>
 
        * tracepoint.c (trace_save): Change utp->actions to
index 58fc8d40971e178032aef89c3ad47efb2d2d1991..3484d7ad3b61aea01dbeccaac4f479910fc15920 100644 (file)
@@ -3991,7 +3991,7 @@ tfile_xfer_partial (struct target_ops *ops, enum target_object object,
     {
       asection *s;
       bfd_size_type size;
-      bfd_vma lma;
+      bfd_vma vma;
 
       for (s = exec_bfd->sections; s; s = s->next)
        {
@@ -3999,16 +3999,16 @@ tfile_xfer_partial (struct target_ops *ops, enum target_object object,
              (s->flags & SEC_READONLY) == 0)
            continue;
 
-         lma = s->lma;
+         vma = s->vma;
          size = bfd_get_section_size (s);
-         if (lma <= offset && offset < (lma + size))
+         if (vma <= offset && offset < (vma + size))
            {
-             amt = (lma + size) - offset;
+             amt = (vma + size) - offset;
              if (amt > len)
                amt = len;
 
              amt = bfd_get_section_contents (exec_bfd, s,
-                                             readbuf, offset - lma, amt);
+                                             readbuf, offset - vma, amt);
              return amt;
            }
        }