gdb/
authorDaniel Jacobowitz <drow@false.org>
Tue, 16 Feb 2010 21:18:46 +0000 (21:18 +0000)
committerDaniel Jacobowitz <drow@false.org>
Tue, 16 Feb 2010 21:18:46 +0000 (21:18 +0000)
* infcmd.c (show_inferior_tty_command): Check for NULL.
Correct output message.

gdb/ChangeLog
gdb/infcmd.c

index d7d71fd..077528a 100644 (file)
@@ -1,5 +1,10 @@
 2010-02-16  Daniel Jacobowitz  <dan@codesourcery.com>
 
+       * infcmd.c (show_inferior_tty_command): Check for NULL.
+       Correct output message.
+
+2010-02-16  Daniel Jacobowitz  <dan@codesourcery.com>
+
        * linespec.c (decode_line_1): Handle FILE:FUNCTION even if
        FUNCTION contains parentheses.  Improve removal of a trailing
        single quote.
index f99a4ae..29cf427 100644 (file)
@@ -197,10 +197,12 @@ show_inferior_tty_command (struct ui_file *file, int from_tty,
 {
   /* Note that we ignore the passed-in value in favor of computing it
      directly.  */
+  const char *inferior_io_terminal = get_inferior_io_terminal ();
+  if (inferior_io_terminal == NULL)
+    inferior_io_terminal = "";
   fprintf_filtered (gdb_stdout,
-                   _("argument list to give program being debugged when "
-                     "it is started is %s"),
-                   get_inferior_io_terminal ());
+                   _("Terminal for future runs of program being debugged "
+                     "is \"%s\".\n"), inferior_io_terminal);
 }
 
 char *