2003-11-06 Andrew Cagney <cagney@redhat.com>
authorAndrew Cagney <cagney@redhat.com>
Thu, 6 Nov 2003 19:56:26 +0000 (19:56 +0000)
committerAndrew Cagney <cagney@redhat.com>
Thu, 6 Nov 2003 19:56:26 +0000 (19:56 +0000)
    Jeff Johnston  <jjohnstn@redhat.com>

* target.c (add_target): Only set "to_xfer_partial" when NULL.
(init_dummy_target): Set "to_xfer_partial".

gdb/ChangeLog
gdb/target.c

index 257638b90586b449363f44593998b70e2b28352d..9f36dd967fa186313c3e754ea18167b92a0457c5 100644 (file)
@@ -1,3 +1,9 @@
+2003-11-06  Andrew Cagney  <cagney@redhat.com>
+           Jeff Johnston  <jjohnstn@redhat.com>
+
+       * target.c (add_target): Only set "to_xfer_partial" when NULL.
+       (init_dummy_target): Set "to_xfer_partial".
+
 2003-11-06  Andrew Cagney  <cagney@redhat.com>
 
        * stack.c (return_command): Warn when STRUCT_CONVENTION, and not
index a21fd9f1d37436360dbfd3f81e17b40dda78714d..93087608b2d71a167b9ee5887796e68f80dd8699 100644 (file)
@@ -220,7 +220,8 @@ void
 add_target (struct target_ops *t)
 {
   /* Provide default values for all "must have" methods.  */
-  t->to_xfer_partial = default_xfer_partial;
+  if (t->to_xfer_partial == NULL)
+    t->to_xfer_partial = default_xfer_partial;
 
   if (!target_structs)
     {
@@ -1644,6 +1645,7 @@ init_dummy_target (void)
   dummy_target.to_stratum = dummy_stratum;
   dummy_target.to_find_memory_regions = dummy_find_memory_regions;
   dummy_target.to_make_corefile_notes = dummy_make_corefile_notes;
+  dummy_target.to_xfer_partial = default_xfer_partial;
   dummy_target.to_magic = OPS_MAGIC;
 }
 \f