aboutsummaryrefslogtreecommitdiff
path: root/gdb/mi
diff options
context:
space:
mode:
authorMarc Khouzam <marc.khouzam@ericsson.com>2010-12-22 18:30:19 +0000
committerMarc Khouzam <marc.khouzam@ericsson.com>2010-12-22 18:30:19 +0000
commit8fa067afb27618ea0b54d76b8096faca0d7ab0e7 (patch)
tree8dded990d24b393995aa25b8334e469cc9749dc9 /gdb/mi
parentab73a86628f0511cd9ef39e3cad557739e5af7ce (diff)
downloadgdb-8fa067afb27618ea0b54d76b8096faca0d7ab0e7.zip
gdb-8fa067afb27618ea0b54d76b8096faca0d7ab0e7.tar.gz
gdb-8fa067afb27618ea0b54d76b8096faca0d7ab0e7.tar.bz2
* inferior.c (remove_inferior_command): Don't remove an active inferior.
* mi/mi-main.c (mi_cmd_remove_inferior): Ditto.
Diffstat (limited to 'gdb/mi')
-rw-r--r--gdb/mi/mi-main.c3
1 files changed, 3 insertions, 0 deletions
diff --git a/gdb/mi/mi-main.c b/gdb/mi/mi-main.c
index b03a8b9..6f66e89 100644
--- a/gdb/mi/mi-main.c
+++ b/gdb/mi/mi-main.c
@@ -1772,6 +1772,9 @@ mi_cmd_remove_inferior (char *command, char **argv, int argc)
if (!inf)
error ("the specified thread group does not exist");
+ if (inf->pid != 0)
+ error ("can not remove an active inferior");
+
if (inf == current_inferior ())
{
struct thread_info *tp = 0;