david/ipxe
david
/
ipxe
Archived
1
0
Fork 0

[netdevice] Fix failure path in register_netdev()

Signed-off-by: Michael Brown <mcb30@ipxe.org>
This commit is contained in:
Michael Brown 2016-05-20 20:43:58 +01:00
parent 56c0147deb
commit 231adda40f
1 changed files with 2 additions and 0 deletions

View File

@ -733,6 +733,8 @@ int register_netdev ( struct net_device *netdev ) {
clear_settings ( netdev_settings ( netdev ) );
unregister_settings ( netdev_settings ( netdev ) );
err_register_settings:
list_del ( &netdev->list );
netdev_put ( netdev );
err_duplicate:
return rc;
}