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: fix list/edit command in hook-stop


> Date: Thu, 23 Feb 2006 16:13:01 -0600
> From: Jason Kraftcheck <kraftche@cae.wisc.edu>
> CC: gdb-patches@sources.redhat.com
> 
> --- gdb-6.4/gdb/infrun.c	2005-11-14 09:35:16.000000000 -0600
> +++ mod/gdb/infrun.c	2006-02-23 15:28:44.485723627 -0600
> @@ -3041,8 +3041,12 @@ Further execution is probably impossible
>    /* Look up the hook_stop and run it (CLI internally handles problem
>       of stop_command's pre-hook not existing).  */
>    if (stop_command)
> -    catch_errors (hook_stop_stub, stop_command,
> -		  "Error while running hook_stop:\n", RETURN_MASK_ALL);
> +    {
> +      if (target_has_stack)
> +        set_current_sal_from_frame (get_current_frame (), 1);
> +      catch_errors (hook_stop_stub, stop_command,
> +		    "Error while running hook_stop:\n", RETURN_MASK_ALL);
> +    }
> 

I'd suggest a comment here explaining why set_current_sal_from_frame
is called.


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