[6891] host_device_remove: remove incorrect check for device name ( Eduardo Habkost)
Revision: 6891
http://svn.sv.gnu.org/viewvc/?view=rev&root=qemu&revision=6891 Author: aliguori Date: 2009-03-28 15:58:58 +0000 (Sat, 28 Mar 2009)
Log Message:
-----------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 <[email protected]>
Signed-off-by Anthony Liguori <[email protected]>
Modified Paths:
--------------
trunk/net.c
Modified: trunk/net.c
===================================================================
net.c +0 -5
@@ -1822,11 +1822,6 @@VLANState *vlan;VLANClientState *vc; -if (!net_host_check_device (device)) { -monitor_printf (mon,"invalid host network device %s\n" , device); -return ; - } - vlan =qemu_find_vlan (vlan_id);if (!vlan) {monitor_printf (mon,"can't find vlan %d\n" , vlan_id);