zebra: fix heap-use-after free on ns shutdown (backport #17020) #17141
frrbot / frrbot
completed
Oct 16, 2024 in 6s
Style and/or linter errors found
Style and/or linter errors found
Details
Thanks for your contribution to FRR!
Click for style suggestions
diff --git a/zebra/zebra_ns.c b/zebra/zebra_ns.c
index f4d23de28..e11c90e18 100644
--- a/zebra/zebra_ns.c
+++ b/zebra/zebra_ns.c
@@ -157,7 +157,8 @@ int zebra_ns_early_shutdown(struct ns *ns,
/* During zebra shutdown, do kernel cleanup
* netlink sockets, ..
*/
-int zebra_ns_kernel_shutdown(struct ns *ns, void *param_in __attribute__((unused)),
+int zebra_ns_kernel_shutdown(struct ns *ns,
+ void *param_in __attribute__((unused)),
void **param_out __attribute__((unused)))
{
struct zebra_ns *zns = ns->info;
diff --git a/zebra/zebra_ns.h b/zebra/zebra_ns.h
index 2579dd9cb..738fa1530 100644
--- a/zebra/zebra_ns.h
+++ b/zebra/zebra_ns.h
@@ -69,7 +69,8 @@ int zebra_ns_final_shutdown(struct ns *ns,
<<<<<<< HEAD
int zebra_ns_config_write(struct vty *vty, struct ns *ns);
=======
-int zebra_ns_kernel_shutdown(struct ns *ns, void *param_in __attribute__((unused)),
+int zebra_ns_kernel_shutdown(struct ns *ns,
+ void *param_in __attribute__((unused)),
void **param_out __attribute__((unused)));
void zebra_ns_startup_continue(struct zebra_dplane_ctx *ctx);
To apply the style suggestions:
curl https://gist.githubusercontent.com/polychaeta/4ad46dae9fd564fa0a1383b3be20959a/raw/ffe66c72b6686d540c7892feca0f17ab693de7cc/style.diff | git apply -
If you are a new contributor to FRR, please see our contributing guidelines.
After making changes, you do not need to create a new PR. You should perform an amend or interactive rebase followed by a force push.
Loading