* sparc-tdep.c, a29k-tdep.c, findvar.c (get_saved_register):
authorJim Kingdon <jkingdon@engr.sgi.com>
Tue, 20 Dec 1994 21:06:13 +0000 (21:06 +0000)
committerJim Kingdon <jkingdon@engr.sgi.com>
Tue, 20 Dec 1994 21:06:13 +0000 (21:06 +0000)
if !target_has_registers, call error().

gdb/ChangeLog
gdb/a29k-tdep.c
gdb/sparc-tdep.c

index b6f836f98b01995d93024f884358af98dac545bc..1cceef74de52bee370707261c7d822970c254c7f 100644 (file)
@@ -1,5 +1,8 @@
 Tue Dec 20 11:44:28 1994  Jim Kingdon  (kingdon@lioth.cygnus.com)
 
+       * sparc-tdep.c, a29k-tdep.c, findvar.c (get_saved_register):
+       if !target_has_registers, call error().
+
        * value.h: Remove obsolete comments about FRAME vs struct
        frame_info *.
 
index e3a855fca75c20f235d3f909bd4a34eccac5a39e..dd2f4e8a31d4d0a3f9278b31c0ffac795333f21c 100644 (file)
@@ -667,6 +667,10 @@ get_saved_register (raw_buffer, optimized, addrp, frame, regnum, lvalp)
   CORE_ADDR addr;
   enum lval_type lval;
 
+  if (!target_has_registers)
+    error ("No registers.");
+
+  /* Probably now redundant with the target_has_registers check.  */
   if (frame == 0)
     return;
 
index 59914b1acf63a654ceaadc56202403301210b521..96cea9df105afad15812d4b88a418532bca65ddb 100644 (file)
@@ -519,6 +519,9 @@ get_saved_register (raw_buffer, optimized, addrp, frame, regnum, lval)
   struct frame_info *frame1;
   CORE_ADDR addr;
 
+  if (!target_has_registers)
+    error ("No registers.");
+
   if (optimized)
     *optimized = 0;