]> git.proxmox.com Git - mirror_ubuntu-disco-kernel.git/commit
tipc: check return value of __tipc_dump_start()
authorCong Wang <xiyou.wangcong@gmail.com>
Tue, 11 Sep 2018 22:12:17 +0000 (15:12 -0700)
committerDavid S. Miller <davem@davemloft.net>
Wed, 12 Sep 2018 20:15:04 +0000 (13:15 -0700)
commit12a78b026f870c575d3a98998b25084aac5b3c61
tree534aa89682961cea04a61a35c9ba357afe85088b
parent6b4d24de299be72d96c1f3b318905ccaaf47b904
tipc: check return value of __tipc_dump_start()

When __tipc_dump_start() fails with running out of memory,
we have no reason to continue, especially we should avoid
calling tipc_dump_done().

Fixes: 8f5c5fcf3533 ("tipc: call start and done ops directly in __tipc_nl_compat_dumpit()")
Reported-and-tested-by: syzbot+3f8324abccfbf8c74a9f@syzkaller.appspotmail.com
Cc: Jon Maloy <jon.maloy@ericsson.com>
Cc: Ying Xue <ying.xue@windriver.com>
Signed-off-by: Cong Wang <xiyou.wangcong@gmail.com>
Acked-by: Ying Xue <ying.xue@windriver.com>
Signed-off-by: David S. Miller <davem@davemloft.net>
net/tipc/netlink_compat.c