summaryrefslogtreecommitdiffstats
path: root/fs/ubifs/Makefile
diff options
context:
space:
mode:
authorJeremy Sowden <jeremy@azazel.net>2019-06-16 16:54:37 +0100
committerDavid S. Miller <davem@davemloft.net>2019-06-16 20:44:20 -0700
commit6be8e297f9bcea666ea85ac7a6cd9d52d6deaf92 (patch)
treea883357a7dbcf3e9c81f4541ae0ad47e0c39068d /fs/ubifs/Makefile
parent5cf02612b33f104fe1015b2dfaf1758ad3675588 (diff)
downloadlinux-6be8e297f9bcea666ea85ac7a6cd9d52d6deaf92.tar.gz
linux-6be8e297f9bcea666ea85ac7a6cd9d52d6deaf92.tar.bz2
linux-6be8e297f9bcea666ea85ac7a6cd9d52d6deaf92.zip
lapb: fixed leak of control-blocks.
lapb_register calls lapb_create_cb, which initializes the control- block's ref-count to one, and __lapb_insert_cb, which increments it when adding the new block to the list of blocks. lapb_unregister calls __lapb_remove_cb, which decrements the ref-count when removing control-block from the list of blocks, and calls lapb_put itself to decrement the ref-count before returning. However, lapb_unregister also calls __lapb_devtostruct to look up the right control-block for the given net_device, and __lapb_devtostruct also bumps the ref-count, which means that when lapb_unregister returns the ref-count is still 1 and the control-block is leaked. Call lapb_put after __lapb_devtostruct to fix leak. Reported-by: syzbot+afb980676c836b4a0afa@syzkaller.appspotmail.com Signed-off-by: Jeremy Sowden <jeremy@azazel.net> Signed-off-by: David S. Miller <davem@davemloft.net>
Diffstat (limited to 'fs/ubifs/Makefile')
0 files changed, 0 insertions, 0 deletions