From f786f615100c8763f19ddec9943156cd2b94a763 Mon Sep 17 00:00:00 2001 From: Andrew Cagney Date: Fri, 8 Aug 2003 19:00:08 +0000 Subject: 2003-08-08 Andrew Cagney * interps.c (interp_set): Check for a NULL "old_interp". Index: mi/ChangeLog 2003-08-08 Andrew Cagney * mi-main.c (captured_mi_execute_command): Add "mi2" and "mi3" to interpreters that hack around CLI. * mi-interp.c (mi3_command_loop): New function. (mi_interpreter_resume): Check for "mi3", default to "mi2". --- gdb/interps.c | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) (limited to 'gdb/interps.c') diff --git a/gdb/interps.c b/gdb/interps.c index 6df1d4b..82e9af6 100644 --- a/gdb/interps.c +++ b/gdb/interps.c @@ -183,7 +183,7 @@ interp_set (struct interp *interp) if (interp->procs->resume_proc != NULL && (!interp->procs->resume_proc (interp->data))) { - if (!interp_set (old_interp)) + if (old_interp == NULL || !interp_set (old_interp)) internal_error (__FILE__, __LINE__, "Failed to initialize new interp \"%s\" %s", interp->name, "and could not restore old interp!\n"); -- cgit v1.1