This is the mail archive of the gdb-patches@sources.redhat.com 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: Patch for gdb/mi problem 672


Hi,

Although I know that varobj shouldn't longjmp in case of errors, I don't 
think that this is going to be a safe assumption. I would recommend that 
you refrain from using ui_out_*_begin and ui_out_*_end, and instead use 
make_cleanup_ui_out_*_begin_end and do_cleanups, which will make sure that 
the UIOUT builder is properly reset in case of errors. (See, for example, 
the cleanup that I did in mi_cmd_data_list_registers.)

On Fri, 27 Sep 2002, J. Johnston wrote:

> @@ -419,10 +419,10 @@
>    if ((*name == '*') && (*(name + 1) == '\0'))
>      {
>        nv = varobj_list (&rootlist);
> -      ui_out_tuple_begin (uiout, "changelist");
> +      ui_out_list_begin (uiout, "changelist");
>        if (nv <= 0)
>  	{
> -	  ui_out_tuple_end (uiout);
> +	  ui_out_list_end (uiout);
>  	  return MI_CMD_DONE;
>  	}
>        cr = rootlist;

[Andrew has already addressed the MI0 thing...]

Other than that, I would recommend that it be approved (for whatever 
that's worth).

Keith



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