public inbox for gdb-patches@sourceware.org
 help / color / mirror / Atom feed
* [patch] Do not break while asking with -batch
@ 2010-07-23 17:06 Jan Kratochvil
  2010-07-23 17:40 ` Tom Tromey
  0 siblings, 1 reply; 6+ messages in thread
From: Jan Kratochvil @ 2010-07-23 17:06 UTC (permalink / raw)
  To: gdb-patches

Hi,

there was PR 9591 which originated from a request to safely `gdb_gcore.sh'
even from a very small terminal window.

FSF GDB HEAD currently still asks in such window
	---Type <return> to continue, or q <return> to quit---
and aborts.

OK to check-in?

No regressions on {x86_64,x86_64-m32,i686}-fedora13-linux-gnu.


Thanks,
Jan


gdb/
2010-07-23  Jan Kratochvil  <jan.kratochvil@redhat.com>

	* utils.c (prompt_for_continue): Return on BATCH_FLAG or not
	INPUT_FROM_TERMINAL_P.

--- a/gdb/utils.c
+++ b/gdb/utils.c
@@ -2155,6 +2155,9 @@ prompt_for_continue (void)
   char *ignore;
   char cont_prompt[120];
 
+  if (batch_flag || ! input_from_terminal_p ())
+    return;
+
   if (annotation_level > 1)
     printf_unfiltered (("\n\032\032pre-prompt-for-continue\n"));
 

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

end of thread, other threads:[~2010-07-27 19:17 UTC | newest]

Thread overview: 6+ messages (download: mbox.gz / follow: Atom feed)
-- links below jump to the message on this page --
2010-07-23 17:06 [patch] Do not break while asking with -batch Jan Kratochvil
2010-07-23 17:40 ` Tom Tromey
2010-07-23 18:09   ` Jan Kratochvil
2010-07-23 22:41     ` Tom Tromey
2010-07-27 16:35       ` Joel Brobecker
2010-07-27 19:17         ` Jan Kratochvil

This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox;
as well as URLs for read-only IMAP folder(s) and NNTP newsgroup(s).