Skip to content
Snippets Groups Projects
Commit def689fc authored by Vasiliy Kovalev's avatar Vasiliy Kovalev Committed by Paolo Abeni
Browse files

devlink: fix possible use-after-free and memory leaks in devlink_init()


The pernet operations structure for the subsystem must be registered
before registering the generic netlink family.

Make an unregister in case of unsuccessful registration.

Fixes: 687125b5 ("devlink: split out core code")
Signed-off-by: default avatarVasiliy Kovalev <kovalev@altlinux.org>
Link: https://lore.kernel.org/r/20240215203400.29976-1-kovalev@altlinux.org


Signed-off-by: default avatarPaolo Abeni <pabeni@redhat.com>
parent 5559cea2
No related branches found
No related tags found
No related merge requests found
Loading
0% Loading or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment