summaryrefslogtreecommitdiff
diff options
context:
space:
mode:
authoraliguori <aliguori@c046a42c-6fe2-441c-8c8c-71466251a162>2009-03-28 15:51:46 +0000
committeraliguori <aliguori@c046a42c-6fe2-441c-8c8c-71466251a162>2009-03-28 15:51:46 +0000
commit20a9c6ac7f3dec8cd6f51f9cf9b90e987051a8ac (patch)
tree621d31b385ccb8fc871ca4b52fa36f3b5d5e788f
parentbd0b264c2182f211913e0b1b5190201400aacc0d (diff)
downloadqemu-20a9c6ac7f3dec8cd6f51f9cf9b90e987051a8ac.tar.gz
host_device_remove: remove incorrect check for device name (Eduardo Habkost)
There is no need to check for valid prefixes on the the device name when removing it. If the device name is found on the vlan client list, it can be removed, regardless of the prefix used on its name. To reproduce the bug, just run this on the monitor: (qemu) host_net_add user name=foobar (qemu) host_net_remove 0 foobar invalid host network device foobar (qemu) Signed-off-by: Eduardo Habkost <ehabkost@redhat.com> Signed-off-by: Anthony Liguori <aliguori@us.ibm.com> git-svn-id: svn://svn.savannah.nongnu.org/qemu/branches/stable_0_10@6890 c046a42c-6fe2-441c-8c8c-71466251a162
-rw-r--r--net.c5
1 files changed, 0 insertions, 5 deletions
diff --git a/net.c b/net.c
index 522df03ad4..dc00787e28 100644
--- a/net.c
+++ b/net.c
@@ -1818,11 +1818,6 @@ void net_host_device_remove(int vlan_id, const char *device)
VLANState *vlan;
VLANClientState *vc;
- if (!net_host_check_device(device)) {
- term_printf("invalid host network device %s\n", device);
- return;
- }
-
vlan = qemu_find_vlan(vlan_id);
if (!vlan) {
term_printf("can't find vlan %d\n", vlan_id);