From ae7a4cc898f02f065634191e684770243b9e4a33 Mon Sep 17 00:00:00 2001 From: mmetzger Date: Mon, 11 Mar 2013 08:47:09 +0000 Subject: Provide default target methods for record targets that are likely to be shared between different record targets. gdb/ * record.h (record_disconnect): New. (record_detach): New. (record_mourn_inferior): New. (record_kill): New. * record-full.c (record_disconnect, record_detach, record_mourn_inferior, record_kill): Move to... * record.c: ...here. (DEBUG): New. (record_stop): New. (record_unpush): New. (cmd_record_stop): Call record_stop. Replace unpush_target call with record_unpush call. (record_disconnect, record_detach): Assert that the target is of record stratum. Call record_unpush, record_stop, and DEBUG. (record_mourn_inferior, record_kill): Assert that the target is of record stratum. Call record_unpush and DEBUG. --- gdb/record.h | 12 ++++++++++++ 1 file changed, 12 insertions(+) (limited to 'gdb/record.h') diff --git a/gdb/record.h b/gdb/record.h index b428eaf91c4..04d6b4ac9ff 100644 --- a/gdb/record.h +++ b/gdb/record.h @@ -41,4 +41,16 @@ extern int record_read_memory (struct gdbarch *gdbarch, /* The "record goto" command. */ extern void cmd_record_goto (char *arg, int from_tty); +/* The default "to_disconnect" target method for record targets. */ +extern void record_disconnect (struct target_ops *, char *, int); + +/* The default "to_detach" target method for record targets. */ +extern void record_detach (struct target_ops *, char *, int); + +/* The default "to_mourn_inferior" target method for record targets. */ +extern void record_mourn_inferior (struct target_ops *); + +/* The default "to_kill" target method for record targets. */ +extern void record_kill (struct target_ops *); + #endif /* _RECORD_H_ */ -- cgit v1.2.1