mirror of
https://github.com/hardkernel/linux.git
synced 2026-06-05 02:21:52 +09:00
tun: add a missing rcu_read_unlock() in error path
commit9180bb4f04upstream. In my latest patch I missed one rcu_read_unlock(), in case device is down. Fixes:4477138fa0("tun: properly test for IFF_UP") Signed-off-by: Eric Dumazet <edumazet@google.com> Reported-by: syzbot <syzkaller@googlegroups.com> Signed-off-by: David S. Miller <davem@davemloft.net> Signed-off-by: Greg Kroah-Hartman <gregkh@linuxfoundation.org>
This commit is contained in:
committed by
Greg Kroah-Hartman
parent
63a85fb487
commit
6caa2c1036
@@ -1569,6 +1569,7 @@ drop:
|
||||
rcu_read_lock();
|
||||
if (unlikely(!(tun->dev->flags & IFF_UP))) {
|
||||
err = -EIO;
|
||||
rcu_read_unlock();
|
||||
goto drop;
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user