Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
* Don't paginate "new thread" events
@ 2008-03-12  1:49 Pedro Alves
  2008-03-12  3:01 ` Joel Brobecker
  0 siblings, 1 reply; 6+ messages in thread
From: Pedro Alves @ 2008-03-12  1:49 UTC (permalink / raw)
  To: gdb-patches

[-- Attachment #1: Type: text/plain, Size: 620 bytes --]

New thread events printing ("New Thread 0x40077950 (LWP 13229)]") was
recently centralised in add_thread.  Unfortunatelly it brought with
it a behaviour change.  Before, we wouldn't paginate when these
events filled the terminal screen, and now we do.  This is quite bad,
as gdb now waits for use input to proceed.  Also, since add_thread
doesn't target_terminal_ours, gdb just stops due to SIGTTOU
when the pagination kicks in ("want to continue y or n" prompt).  User
now has to fg to restore it...

Easilly reproduced by running manythreads.exp manually.

This patch restores the old behaviour.

OK?

-- 
Pedro Alves

[-- Attachment #2: dont_paginate_threads.diff --]
[-- Type: text/x-diff, Size: 689 bytes --]

2008-03-12  Pedro Alves  <pedro@codesourcery.com>

	* thread.c (add_thread): Use printf_unfiltered to print.

---
 gdb/thread.c |    2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

Index: src/gdb/thread.c
===================================================================
--- src.orig/gdb/thread.c	2008-03-12 01:36:24.000000000 +0000
+++ src/gdb/thread.c	2008-03-12 01:36:42.000000000 +0000
@@ -136,7 +136,7 @@ add_thread (ptid_t ptid)
   struct thread_info *result = add_thread_silent (ptid);
 
   if (print_thread_events)
-    printf_filtered (_("[New %s]\n"), target_pid_to_str (ptid));
+    printf_unfiltered (_("[New %s]\n"), target_pid_to_str (ptid));
   
   return result;
 }

^ permalink raw reply	[flat|nested] 6+ messages in thread

end of thread, other threads:[~2008-03-12 22:24 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2008-03-12  1:49 Don't paginate "new thread" events Pedro Alves
2008-03-12  3:01 ` Joel Brobecker
2008-03-12  3:13   ` Daniel Jacobowitz
2008-03-12 16:03     ` Joel Brobecker
2008-03-12 22:24       ` Pedro Alves
2008-03-12  3:27   ` Pedro Alves

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox