Skip to content
Commit bb3a420d authored by Peilin Ye's avatar Peilin Ye Committed by David S. Miller
Browse files

tipc: Fix memory leak in tipc_group_create_member()

tipc_group_add_to_tree() returns silently if `key` matches `nkey` of an
existing node, causing tipc_group_create_member() to leak memory. Let
tipc_group_add_to_tree() return an error in such a case, so that
tipc_group_create_member() can handle it properly.

Fixes: 75da2163

 ("tipc: introduce communication groups")
Reported-and-tested-by: default avatar <syzbot+f95d90c454864b3b5bc9@syzkaller.appspotmail.com>
Cc: Hillf Danton <hdanton@sina.com>
Link: https://syzkaller.appspot.com/bug?id=048390604fe1b60df34150265479202f10e13aff
Signed-off-by: default avatarPeilin Ye <yepeilin.cs@gmail.com>
Signed-off-by: default avatarDavid S. Miller <davem@davemloft.net>
parent 1869e226
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