aboutsummaryrefslogtreecommitdiff
path: root/gdb/annotate.c
diff options
context:
space:
mode:
Diffstat (limited to 'gdb/annotate.c')
-rw-r--r--gdb/annotate.c36
1 files changed, 30 insertions, 6 deletions
diff --git a/gdb/annotate.c b/gdb/annotate.c
index cf83a8a..09d31f5 100644
--- a/gdb/annotate.c
+++ b/gdb/annotate.c
@@ -27,6 +27,11 @@ Foundation, Inc., 59 Temple Place - Suite 330, Boston, MA 02111-1307, USA. */
static void print_value_flags PARAMS ((struct type *));
static void breakpoint_changed PARAMS ((struct breakpoint *));
+void (*annotate_starting_hook) PARAMS ((void));
+void (*annotate_stopped_hook) PARAMS ((void));
+void (*annotate_signalled_hook) PARAMS ((void));
+void (*annotate_exited_hook) PARAMS ((void));
+
static void
print_value_flags (t)
struct type *t;
@@ -66,30 +71,49 @@ annotate_watchpoint (num)
void
annotate_starting ()
{
- if (annotation_level > 1)
+
+ if (annotate_starting_hook)
+ annotate_starting_hook ();
+ else
{
- printf_filtered ("\n\032\032starting\n");
+ if (annotation_level > 1)
+ {
+ printf_filtered ("\n\032\032starting\n");
+ }
}
}
void
annotate_stopped ()
{
- if (annotation_level > 1)
- printf_filtered ("\n\032\032stopped\n");
+ if (annotate_stopped_hook)
+ annotate_stopped_hook ();
+ else
+ {
+ if (annotation_level > 1)
+ printf_filtered ("\n\032\032stopped\n");
+ }
}
void
annotate_exited (exitstatus)
int exitstatus;
{
- if (annotation_level > 1)
- printf_filtered ("\n\032\032exited %d\n", exitstatus);
+ if (annotate_exited_hook)
+ annotate_exited_hook ();
+ else
+ {
+ if (annotation_level > 1)
+ printf_filtered ("\n\032\032exited %d\n", exitstatus);
+ }
}
void
annotate_signalled ()
{
+ if (annotate_signalled_hook)
+ annotate_signalled_hook ();
+
if (annotation_level > 1)
printf_filtered ("\n\032\032signalled\n");
}