Skip to content
Commit 43af8532 authored by Volodymyr G Lukiianyk's avatar Volodymyr G Lukiianyk Committed by David S. Miller
Browse files

bridge: fix error handling in br_add_if()



When device is added to bridge its refcnt is incremented (in new_nbp()), but if
error occurs during further br_add_if() operations this counter is not
decremented back. Fix it by adding dev_put() call in the error path.

Signed-off-by: default avatarVolodymyr G Lukiianyk <volodymyrgl@gmail.com>
Signed-off-by: default avatarStephen Hemminger <shemminger@vyatta.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 9a732ed6
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment