Mirror of the gdb-patches mailing list
 help / color / mirror / Atom feed
From: Keith Seitz <keiths@cygnus.com>
To: <gdb-patches@sources.redhat.com>
Cc: Elena Zannoni <ezannoni@cygnus.com>
Subject: [RFA] top.c: initialize other UIs before cli
Date: Wed, 07 Nov 2001 16:33:00 -0000	[thread overview]
Message-ID: <Pine.GSO.4.33.0111191203250.16197-100000@makita.cygnus.com> (raw)

Hi,

There is currently a little problem with init_ui_hook: if the UI fails to
initialize (and we should fall back to "gdb -nw"), then the CLI will NOT
get initialized properly.

This results because init_ui_hook does not return any status indicating
the failure.

This simple change will correct this anomaly without altering init_ui_hook
semantics, i.e., it is absolutely the least intrusive.

?
Keith

ChangeLog
2001-11-19  Keith Seitz  <keiths@redhat.com>

	* top.c (gdb_init): Call init_ui_hook before initializing
	the default UI.

Patch
Index: top.c
===================================================================
RCS file: /cvs/src/src/gdb/top.c,v
retrieving revision 1.48
diff -u -p -r1.48 top.c
--- top.c	2001/11/10 21:34:56	1.48
+++ top.c	2001/11/19 20:01:19
@@ -2034,6 +2034,9 @@ gdb_init (char *argv0)
   set_language (language_c);
   expected_language = current_language;		/* don't warn about the change.  */

+  if (init_ui_hook)
+    init_ui_hook (argv0);
+
 #ifdef UI_OUT
   /* Install the default UI */
   if (!init_ui_hook)
@@ -2050,7 +2053,4 @@ gdb_init (char *argv0)
 	}
     }
 #endif
-
-  if (init_ui_hook)
-    init_ui_hook (argv0);
 }


             reply	other threads:[~2001-11-19 20:06 UTC|newest]

Thread overview: 4+ messages / expand[flat|nested]  mbox.gz  Atom feed  top
2001-11-07 16:33 Keith Seitz [this message]
2001-11-07 17:25 ` Keith Seitz
2001-11-08  2:06   ` Elena Zannoni
2001-11-08  4:07     ` Keith Seitz

Reply instructions:

You may reply publicly to this message via plain-text email
using any one of the following methods:

* Save the following mbox file, import it into your mail client,
  and reply-to-all from there: mbox

  Avoid top-posting and favor interleaved quoting:
  https://en.wikipedia.org/wiki/Posting_style#Interleaved_style

* Reply using the --to, --cc, and --in-reply-to
  switches of git-send-email(1):

  git send-email \
    --in-reply-to=Pine.GSO.4.33.0111191203250.16197-100000@makita.cygnus.com \
    --to=keiths@cygnus.com \
    --cc=ezannoni@cygnus.com \
    --cc=gdb-patches@sources.redhat.com \
    /path/to/YOUR_REPLY

  https://kernel.org/pub/software/scm/git/docs/git-send-email.html

* If your mail client supports setting the In-Reply-To header
  via mailto: links, try the mailto: link
Be sure your reply has a Subject: header at the top and a blank line before the message body.
This is a public inbox, see mirroring instructions
for how to clone and mirror all data and code used for this inbox