Accepting request 1031212 from Base:System
- run tests - add Avoid-double-free-on-deinit_thermal.patch (bsc#1204607) - build with thermald support on x86_64 (jsc#PED-1039) OBS-URL: https://build.opensuse.org/request/show/1031212 OBS-URL: https://build.opensuse.org/package/show/openSUSE:Factory/irqbalance?expand=0&rev=67
This commit is contained in:
commit
538b75661c
41
Avoid-double-free-on-deinit_thermal.patch
Normal file
41
Avoid-double-free-on-deinit_thermal.patch
Normal file
@ -0,0 +1,41 @@
|
||||
From b25b1f92ca88aa9f268c93d0d7f66efc0ebf840b Mon Sep 17 00:00:00 2001
|
||||
From: =?UTF-8?q?Dirk=20M=C3=BCller?= <dirk@dmllr.de>
|
||||
Date: Tue, 25 Oct 2022 23:33:14 +0200
|
||||
Subject: [PATCH] Avoid double free on deinit_thermal()
|
||||
MIME-Version: 1.0
|
||||
Content-Type: text/plain; charset=UTF-8
|
||||
Content-Transfer-Encoding: 8bit
|
||||
|
||||
init_thermal() calls deinit_thermal() on error condition,
|
||||
as well as main() calls deinit_thermal() again, causing
|
||||
a double-free.
|
||||
|
||||
Signed-off-by: Dirk Müller <dirk@dmllr.de>
|
||||
---
|
||||
thermal.c | 10 ++++++++--
|
||||
1 file changed, 8 insertions(+), 2 deletions(-)
|
||||
|
||||
diff --git a/thermal.c b/thermal.c
|
||||
index 64a9cdf..1d44104 100644
|
||||
--- a/thermal.c
|
||||
+++ b/thermal.c
|
||||
@@ -506,8 +506,14 @@ static gboolean set_netlink_nonblocking(void)
|
||||
|
||||
void deinit_thermal(void)
|
||||
{
|
||||
- nl_cb_put(callback);
|
||||
- nl_socket_free(sock);
|
||||
+ if (callback) {
|
||||
+ nl_cb_put(callback);
|
||||
+ callback = NULL;
|
||||
+ }
|
||||
+ if (sock) {
|
||||
+ nl_socket_free(sock);
|
||||
+ sock = NULL;
|
||||
+ }
|
||||
}
|
||||
|
||||
/*
|
||||
--
|
||||
2.38.0
|
||||
|
@ -1,8 +1,14 @@
|
||||
-------------------------------------------------------------------
|
||||
Tue Oct 25 21:09:07 UTC 2022 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- run tests
|
||||
- add Avoid-double-free-on-deinit_thermal.patch (bsc#1204607)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Tue Oct 18 21:15:49 UTC 2022 - Dirk Müller <dmueller@suse.com>
|
||||
|
||||
- add uninitialized.patch (bsc#1204371)
|
||||
- build with thermald support on x86_64 (jsc#PED-754)
|
||||
- build with thermald support on x86_64 (jsc#PED-1039)
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Thu Oct 13 09:03:59 UTC 2022 - Dirk Müller <dmueller@suse.com>
|
||||
@ -17,9 +23,6 @@ Thu Oct 13 09:03:59 UTC 2022 - Dirk Müller <dmueller@suse.com>
|
||||
* irqbalance-ui: able to scroll and show coulist and irqs' name
|
||||
- drop proc-interrupts.patch (upstream)
|
||||
D proc-interrupts.patch
|
||||
- Includes the patches for feature:
|
||||
jsc#PED-754
|
||||
Enable IRQ Balancer to support SoC die during low power state
|
||||
|
||||
-------------------------------------------------------------------
|
||||
Wed Aug 17 21:39:04 UTC 2022 - dmueller@suse.com
|
||||
|
@ -31,6 +31,8 @@ Source: https://github.com/Irqbalance/irqbalance/archive/refs/tags/v%{ve
|
||||
Source3: sysconfig.irqbalance
|
||||
Patch1: Set-fd-limit.patch
|
||||
Patch2: uninitialized.patch
|
||||
# https://github.com/Irqbalance/irqbalance/pull/243
|
||||
Patch3: Avoid-double-free-on-deinit_thermal.patch
|
||||
BuildRequires: libcap-ng-devel
|
||||
BuildRequires: libtool
|
||||
BuildRequires: ncurses-devel
|
||||
@ -84,6 +86,9 @@ sed -ie "s|After=syslog.target||g" misc/irqbalance.service
|
||||
install -D -m 0644 misc/irqbalance.service %{buildroot}%{_unitdir}/irqbalance.service
|
||||
ln -s %{_sbindir}/service %{buildroot}%{_sbindir}/rcirqbalance
|
||||
|
||||
%check
|
||||
%make_build check
|
||||
|
||||
%pre
|
||||
%service_add_pre irqbalance.service
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user