[gnome-builder] threading: allow repeated calls to supervisor
- From: Christian Hergert <chergert src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-builder] threading: allow repeated calls to supervisor
- Date: Thu, 4 Mar 2021 01:08:35 +0000 (UTC)
commit 36f24b8264a867698243b2756eee2d038ebfdfbf
Author: Christian Hergert <chergert redhat com>
Date: Wed Mar 3 17:07:50 2021 -0800
threading: allow repeated calls to supervisor
src/libide/threading/ide-subprocess-supervisor.c | 6 ++++++
1 file changed, 6 insertions(+)
---
diff --git a/src/libide/threading/ide-subprocess-supervisor.c
b/src/libide/threading/ide-subprocess-supervisor.c
index 820ace934..7b8885612 100644
--- a/src/libide/threading/ide-subprocess-supervisor.c
+++ b/src/libide/threading/ide-subprocess-supervisor.c
@@ -222,6 +222,9 @@ ide_subprocess_supervisor_start (IdeSubprocessSupervisor *self)
g_return_if_fail (IDE_IS_SUBPROCESS_SUPERVISOR (self));
+ if (priv->supervising)
+ return;
+
if (priv->launcher == NULL)
{
g_warning ("Cannot supervise process, no launcher has been set");
@@ -278,6 +281,9 @@ ide_subprocess_supervisor_stop (IdeSubprocessSupervisor *self)
g_return_if_fail (IDE_IS_SUBPROCESS_SUPERVISOR (self));
+ if (!priv->supervising)
+ return;
+
if (priv->launcher == NULL)
{
g_warning ("Cannot unsupervise process, no launcher has been set");
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]