diff --git a/backport-vrrp-free-script-path-for-notify-scripts-if-set.patch b/backport-vrrp-free-script-path-for-notify-scripts-if-set.patch new file mode 100644 index 0000000000000000000000000000000000000000..86bf447ba56186aec7a6b6e351a20032eac45dcf --- /dev/null +++ b/backport-vrrp-free-script-path-for-notify-scripts-if-set.patch @@ -0,0 +1,25 @@ +From de8e605f356f007c3f4cc2499282af9fbe290428 Mon Sep 17 00:00:00 2001 +From: Quentin Armitage +Date: Tue, 9 Jul 2024 21:04:04 +0100 +Subject: [PATCH 1/1] vrrp: free script->path for notify scripts if set + +Signed-off-by: Quentin Armitage +--- + lib/notify.h | 1 + + 1 file changed, 1 insertion(+) + +diff --git a/lib/notify.h b/lib/notify.h +index 19b40957..aa716c40 100644 +--- a/lib/notify.h ++++ b/lib/notify.h +@@ -82,6 +82,7 @@ free_notify_script(notify_script_t **script) + if (!*script) + return; + FREE_PTR((*script)->args); ++ FREE_CONST_PTR((*script)->path); + FREE_PTR(*script); + *script = NULL; + } +-- +2.20.1 + diff --git a/keepalived.spec b/keepalived.spec index f52ffa1c118a44bd9fac6dd79a3e69176063db83..f70def8018addd8ac13fb5b73e22d6b986c84384 100644 --- a/keepalived.spec +++ b/keepalived.spec @@ -9,7 +9,7 @@ Name: keepalived Version: 2.3.1 -Release: 1 +Release: 2 Summary: High Availability monitor built upon LVS, VRRP and service pollers License: GPLv2+ URL: http://www.keepalived.org/ @@ -18,6 +18,7 @@ Source1: keepalived.service Source2: keepalived-stop-post.sh Source3: keepalived-start-post.sh Source4: keepalived-pid-check.sh +Patch0: backport-vrrp-free-script-path-for-notify-scripts-if-set.patch Requires(post): systemd Requires(preun): systemd @@ -102,6 +103,12 @@ install -Dd -m 0755 %{buildroot}%{_libexecdir}/keepalived %{_mandir}/man* %changelog +* Mon Oct 20 2025 lvgenggeng - 2.3.1-2 +- Type:backport +- ID:NA +- SUG:NA +- DESC: fix potential memory leak issues + * Thu Jun 20 2024 zouzhimin - 2.3.1-1 - Type:bugfix - ID:NA