+2001-09-18 Andrew Cagney <ac131313@redhat.com>
+
+ * thread.c (do_captured_thread_select): Add uiout parameter.
+ (do_captured_list_thread_ids): Ditto.
+ * breakpoint.c (do_captured_breakpoint_query): Ditto.
+
+ * breakpoint.c (gdb_breakpoint_query): Update. Use
+ catch_exceptions.
+ * thread.c (gdb_list_thread_ids): Ditto.
+ (gdb_thread_select): Ditto.
+ (thread_command): Pass uiout to gdb_thread_select.
+
+ * gdb.h (gdb_breakpoint_query): Add parameter ui_out.
+ (gdb_thread_select, gdb_list_thread_ids): Ditto.
+
2001-09-13 Kevin Buettner <kevinb@redhat.com>
From Ilya Golubev <gin@mo.msk.ru>:
};
static int
-do_captured_breakpoint_query (void *data)
+do_captured_breakpoint_query (struct ui_out *uiout, void *data)
{
struct captured_breakpoint_query_args *args = data;
register struct breakpoint *b;
}
enum gdb_rc
-gdb_breakpoint_query (/* output object, */ int bnum)
+gdb_breakpoint_query (struct ui_out *uiout, int bnum)
{
struct captured_breakpoint_query_args args;
args.bnum = bnum;
/* For the moment we don't trust print_one_breakpoint() to not throw
an error. */
- return catch_errors (do_captured_breakpoint_query, &args,
- NULL, RETURN_MASK_ALL);
+ return catch_exceptions (uiout, do_captured_breakpoint_query, &args,
+ NULL, RETURN_MASK_ALL);
}
/* Return non-zero if B is user settable (breakpoints, watchpoints,
/* Print the specified breakpoint on GDB_STDOUT. (Eventually this
function will ``print'' the object on ``output''). */
-enum gdb_rc gdb_breakpoint_query (/* struct {ui,gdb}_out *output, */ int bnum);
+enum gdb_rc gdb_breakpoint_query (struct ui_out *uiout, int bnum);
/* Create a breakpoint at ADDRESS (a GDB source and line). */
enum gdb_rc gdb_breakpoint (char *address, char *condition,
int thread, int ignore_count);
/* Switch thread and print notification. */
-enum gdb_rc gdb_thread_select (/* output object */ char *tidstr);
+enum gdb_rc gdb_thread_select (struct ui_out *uiout, char *tidstr);
/* Print a list of known thread ids. */
-enum gdb_rc gdb_list_thread_ids (/* output object */);
+enum gdb_rc gdb_list_thread_ids (struct ui_out *uiout);
#endif
+2001-09-18 Andrew Cagney <ac131313@redhat.com>
+
+ * mi-main.c (mi_cmd_thread_select): Pass uiout to
+ gdb_thread_select.
+ (mi_cmd_thread_list_ids): Pass uiout to gdb_list_thread_ids.
+
+ * mi-cmd-break.c (breakpoint_notify): Pass uiout to
+ gdb_breakpoint_query.
+
2001-08-17 Keith Seitz <keiths@redhat.com>
* mi-cmd-var.c (varobj_update_one): Update call to
static void
breakpoint_notify (int b)
{
- gdb_breakpoint_query (b);
+ gdb_breakpoint_query (uiout, b);
}
return MI_CMD_ERROR;
}
else
- rc = gdb_thread_select (argv[0]);
+ rc = gdb_thread_select (uiout, argv[0]);
if (rc == GDB_RC_FAIL)
return MI_CMD_CAUGHT_ERROR;
}
else
#ifdef UI_OUT
- rc = gdb_list_thread_ids ();
+ rc = gdb_list_thread_ids (uiout);
#endif
if (rc == GDB_RC_FAIL)
/* Print a list of thread ids currently known, and the total number of
threads. To be used from within catch_errors. */
static int
-do_captured_list_thread_ids (void *arg)
+do_captured_list_thread_ids (struct ui_out *uiout,
+ void *arg)
{
struct thread_info *tp;
int num = 0;
/* Official gdblib interface function to get a list of thread ids and
the total number. */
enum gdb_rc
-gdb_list_thread_ids (/* output object */)
+gdb_list_thread_ids (struct ui_out *uiout)
{
- return catch_errors (do_captured_list_thread_ids, NULL,
- NULL, RETURN_MASK_ALL);
+ return catch_exceptions (uiout, do_captured_list_thread_ids, NULL,
+ NULL, RETURN_MASK_ALL);
}
#endif
return;
}
- gdb_thread_select (tidstr);
+ gdb_thread_select (uiout, tidstr);
}
static int
-do_captured_thread_select (void *tidstr)
+do_captured_thread_select (struct ui_out *uiout,
+ void *tidstr)
{
int num;
struct thread_info *tp;
}
enum gdb_rc
-gdb_thread_select (char *tidstr)
+gdb_thread_select (struct ui_out *uiout,
+ char *tidstr)
{
- return catch_errors (do_captured_thread_select, tidstr,
- NULL, RETURN_MASK_ALL);
+ return catch_exceptions (uiout, do_captured_thread_select, tidstr,
+ NULL, RETURN_MASK_ALL);
}
/* Commands with a prefix of `thread'. */