This is the mail archive of the
gdb-patches@sources.redhat.com
mailing list for the GDB project.
PATCH: Minor cleanup for Insight command-line
- To: gdb-patches at sources dot redhat dot com
- Subject: PATCH: Minor cleanup for Insight command-line
- From: Tom Tromey <tromey at redhat dot com>
- Date: 02 Oct 2001 17:08:16 -0600
- Reply-To: tromey at redhat dot com
I recently submitted an Insight patch which changes how external
editors are handled. It has already been approved. The Insight patch
requires a minor gdb/main.c patch, which is appended.
I think this patch should be uncontroversial because it only removes
code, including a global variable.
We can't get rid of `--enable-external-editor', unfortunately, as
existing Source Navigator installs will still use it.
Ok to commit? My Insight patch is waiting on this. If I check that
patch in without this, gdb won't build.
Tom
Index: ChangeLog
from Tom Tromey <tromey@redhat.com>
* main.c (enable_external_editor): Don't declare.
(captured_main): Don't set enable_external_editor.
Index: main.c
===================================================================
RCS file: /cvs/src/src/gdb/main.c,v
retrieving revision 1.12
diff -u -r1.12 main.c
--- main.c 2001/07/14 18:59:07 1.12
+++ main.c 2001/10/02 19:15:37
@@ -81,7 +81,6 @@
/* These two are used to set the external editor commands when gdb is farming
out files to be edited by another program. */
-extern int enable_external_editor;
extern char *external_editor_command;
/* Call command_loop. If it happens to return, pass that through as a
@@ -341,23 +340,10 @@
break;
}
case 'y':
- {
- /*
- * This enables the edit/button in the main window, even
- * when IDE_ENABLED is set to false. In this case you must
- * use --tclcommand to specify a tcl/script to be called,
- * Tcl/Variable to store the edit/command is:
- * external_editor
- */
- enable_external_editor = 1;
- break;
- }
+ /* Backwards compatibility only. */
+ break;
case 'w':
{
- /*
- * if editor command is enabled, both flags are set
- */
- enable_external_editor = 1;
external_editor_command = xstrdup (optarg);
break;
}