* exec.c (xfer_memory): Add attrib argument.
[deliverable/binutils-gdb.git] / gdb / blockframe.c
index 2352cdf70cc97d0c55276930c06ca27c7ed0060d..eec0e109e82d8690be2825ea47de43bb7357f457 100644 (file)
@@ -393,13 +393,13 @@ get_prev_frame (struct frame_info *next_frame)
     obstack_alloc (&frame_cache_obstack,
                   sizeof (struct frame_info));
 
-  prev->saved_regs = NULL;
+  /* Zero all fields by default.  */
+  memset (prev, 0, sizeof (struct frame_info));
+
   if (next_frame)
     next_frame->prev = prev;
   prev->next = next_frame;
-  prev->prev = (struct frame_info *) 0;
   prev->frame = address;
-  prev->signal_handler_caller = 0;
 
 /* This change should not be needed, FIXME!  We should
    determine whether any targets *need* INIT_FRAME_PC to happen
@@ -1037,7 +1037,7 @@ pc_in_call_dummy_at_entry_point (CORE_ADDR pc, CORE_ADDR sp,
  * The following code serves to maintain the dummy stack frames for
  * inferior function calls (ie. when gdb calls into the inferior via
  * call_function_by_hand).  This code saves the machine state before 
- * the call in host memory, so we must maintain an independant stack 
+ * the call in host memory, so we must maintain an independent stack 
  * and keep it consistant etc.  I am attempting to make this code 
  * generic enough to be used by many targets.
  *
@@ -1137,8 +1137,8 @@ generic_push_dummy_frame (void)
     if (INNER_THAN (dummy_frame->fp, fp))      /* stale -- destroy! */
       {
        dummy_frame_stack = dummy_frame->next;
-       free (dummy_frame->registers);
-       free (dummy_frame);
+       xfree (dummy_frame->registers);
+       xfree (dummy_frame);
        dummy_frame = dummy_frame_stack;
       }
     else
@@ -1193,8 +1193,8 @@ generic_pop_dummy_frame (void)
   write_register_bytes (0, dummy_frame->registers, REGISTER_BYTES);
   flush_cached_frames ();
 
-  free (dummy_frame->registers);
-  free (dummy_frame);
+  xfree (dummy_frame->registers);
+  xfree (dummy_frame);
 }
 
 /* Function: frame_chain_valid 
@@ -1249,7 +1249,7 @@ generic_fix_call_dummy (char *dummy, CORE_ADDR pc, CORE_ADDR fun, int nargs,
    calculated rather than fetched).  We will use not_lval for values
    fetched from generic dummy frames.
 
-   Set *ADDRP to the address, either in memory on as a REGISTER_BYTE
+   Set *ADDRP to the address, either in memory or as a REGISTER_BYTE
    offset into the registers array.  If the value is stored in a dummy
    frame, set *ADDRP to zero.
 
This page took 0.023669 seconds and 4 git commands to generate.