Use target_terminal_ours_for_output in infcmd.c
authorPedro Alves <palves@redhat.com>
Tue, 12 Apr 2016 15:49:31 +0000 (16:49 +0100)
committerPedro Alves <palves@redhat.com>
Tue, 12 Apr 2016 15:58:55 +0000 (16:58 +0100)
We're only doing output here, so leave raw/cooked mode alone, as well
as the SIGINT handler.

No need to restore terminal settings, we'll set inferior modes on the
following resume.

gdb/ChangeLog:
2016-04-12  Pedro Alves  <palves@redhat.com>

* infcmd.c (post_create_inferior, prepare_one_step): Use
target_terminal_ours_for_output instead of target_terminal_ours.

gdb/ChangeLog
gdb/infcmd.c

index 857d5e54c24c6e889608a16a5136fd65a64209ae..0de7a6db9d8dad13b14725ccd248351fb47499a9 100644 (file)
@@ -1,3 +1,8 @@
+2016-04-12  Pedro Alves  <palves@redhat.com>
+
+       * infcmd.c (post_create_inferior, prepare_one_step): Use
+       target_terminal_ours_for_output instead of target_terminal_ours.
+
 2016-04-12  Pedro Alves  <palves@redhat.com>
 
        * exceptions.c (print_flush): Use target_terminal_ours_for_output
index 3a0265f1957846b313ae08fd81b092a5ad4ff935..a80b4c6f03774f87fb25b0212d59cdead5e8543c 100644 (file)
@@ -406,7 +406,7 @@ post_create_inferior (struct target_ops *target, int from_tty)
 {
 
   /* Be sure we own the terminal in case write operations are performed.  */ 
-  target_terminal_ours ();
+  target_terminal_ours_for_output ();
 
   /* If the target hasn't taken care of this already, do it now.
      Targets which need to access registers during to_open,
@@ -1128,7 +1128,7 @@ prepare_one_step (struct step_command_fsm *sm)
                                            &tp->control.step_range_end) == 0)
                error (_("Cannot find bounds of current function"));
 
-             target_terminal_ours ();
+             target_terminal_ours_for_output ();
              printf_filtered (_("Single stepping until exit from function %s,"
                                 "\nwhich has no line number information.\n"),
                               name);