summaryrefslogtreecommitdiff
path: root/backport-Leaking-zombie-child-processes.patch
diff options
context:
space:
mode:
authorCoprDistGit <infra@openeuler.org>2025-10-07 16:18:00 +0000
committerCoprDistGit <infra@openeuler.org>2025-10-07 16:18:00 +0000
commitadf82f3f43427e1fb8052d2583946343651407b4 (patch)
tree0768c0aff12a5d98d1b9ac93f9761037fd03c9be /backport-Leaking-zombie-child-processes.patch
parent5f3f6518f2f73ac2a5e9136f5f0e212ab173a291 (diff)
automatic import of polkit
Diffstat (limited to 'backport-Leaking-zombie-child-processes.patch')
-rw-r--r--backport-Leaking-zombie-child-processes.patch33
1 files changed, 33 insertions, 0 deletions
diff --git a/backport-Leaking-zombie-child-processes.patch b/backport-Leaking-zombie-child-processes.patch
new file mode 100644
index 0000000..8d05a22
--- /dev/null
+++ b/backport-Leaking-zombie-child-processes.patch
@@ -0,0 +1,33 @@
+From 8638ec5cd534dcc616b68e5b0744c493c0c71dc9 Mon Sep 17 00:00:00 2001
+From: Jan Rybar <jrybar@redhat.com>
+Date: Wed, 15 Aug 2018 16:11:22 +0200
+Subject: [PATCH] Leaking zombie child processes Resolves: bz#106021
+
+Subject: [PATCH] polkitd: fix zombie not reaped when js spawned process timed
+ out
+
+The child watch source attached to thread context didn't work due
+to the release of it's main loop and context outside. So we attach
+the source to the global default main context to make it work and
+avoid zombies.
+---
+ src/polkitbackend/polkitbackendcommon.c | 3 ++-
+ 1 file changed, 2 insertions(+), 1 deletion(-)
+
+diff --git a/src/polkitbackend/polkitbackendcommon.c b/src/polkitbackend/polkitbackendcommon.c
+index 517f3c6..7602714 100644
+--- a/src/polkitbackend/polkitbackendcommon.c
++++ b/src/polkitbackend/polkitbackendcommon.c
+@@ -1595,7 +1595,8 @@ utils_spawn_data_free (UtilsSpawnData *data)
+ (GSourceFunc) utils_child_watch_from_release_cb,
+ source,
+ (GDestroyNotify) g_source_destroy);
+- g_source_attach (source, data->main_context);
++ /* attach source to the global default main context */
++ g_source_attach (source, NULL);
+ g_source_unref (source);
+ data->child_pid = 0;
+ }
+--
+2.33.0
+