2005-02-14 22:10:53 +00:00
|
|
|
2005-02-14 Jeff Johnston <jjohnstn@redhat.com>
|
|
|
|
|
|
|
|
* top.c (gdb_readline_wrapper): Ensure terminal is gdb's before calling
|
|
|
|
readline.
|
|
|
|
|
2007-11-01 20:24:20 +00:00
|
|
|
2007-10-14 Jan Kratochvil <jan.kratochvil@redhat.com>
|
|
|
|
|
|
|
|
Port to GDB-6.7.
|
|
|
|
|
|
|
|
Index: gdb-6.7/gdb/top.c
|
2006-07-11 06:33:02 +00:00
|
|
|
===================================================================
|
2007-11-01 20:24:20 +00:00
|
|
|
--- gdb-6.7.orig/gdb/top.c 2007-09-02 23:13:56.000000000 +0200
|
|
|
|
+++ gdb-6.7/gdb/top.c 2007-10-14 23:38:27.000000000 +0200
|
|
|
|
@@ -795,6 +795,14 @@ gdb_readline_wrapper (char *prompt)
|
|
|
|
|
|
|
|
back_to = make_cleanup (gdb_readline_wrapper_cleanup, cleanup);
|
2005-02-14 22:10:53 +00:00
|
|
|
|
|
|
|
+ /* Before calling readline, ensure we have the terminal. If we don't
|
|
|
|
+ have the terminal and call readline, we risk the possibility of
|
|
|
|
+ gdb being thrown into the background. This problem occurs when
|
|
|
|
+ we attach to a background process on the same terminal the background
|
|
|
|
+ process was started from and then perform some action which requires
|
|
|
|
+ a page break prompt. */
|
|
|
|
+ terminal_ours ();
|
|
|
|
+
|
2007-11-01 20:24:20 +00:00
|
|
|
/* Display our prompt and prevent double prompt display. */
|
|
|
|
display_gdb_prompt (prompt);
|
|
|
|
rl_already_prompted = 1;
|