[gnome-remote-desktop] rdp-server: Tear down NVENC after sessions
- From: Jonas Ådahl <jadahl src gnome org>
- To: commits-list gnome org
- Cc:
- Subject: [gnome-remote-desktop] rdp-server: Tear down NVENC after sessions
- Date: Fri, 25 Feb 2022 20:19:19 +0000 (UTC)
commit 64291c6bc0ea7a064c5c63f6214b30deb4ab4927
Author: Jonas Ådahl <jadahl gmail com>
Date: Thu Feb 10 11:33:55 2022 +0100
rdp-server: Tear down NVENC after sessions
Sessions borrow the NVENC instance from the server; if we tear it down
before tearing down the sessions, they may crash as it disappeared under
their feet.
Fix this by destroying the NVENC subsystem after the sessions when
disabling the RDP server.
src/grd-rdp-server.c | 8 ++++----
1 file changed, 4 insertions(+), 4 deletions(-)
---
diff --git a/src/grd-rdp-server.c b/src/grd-rdp-server.c
index 422a1f3e..928a3faa 100644
--- a/src/grd-rdp-server.c
+++ b/src/grd-rdp-server.c
@@ -221,10 +221,6 @@ grd_rdp_server_dispose (GObject *object)
{
GrdRdpServer *rdp_server = GRD_RDP_SERVER (object);
-#ifdef HAVE_HWACCEL_NVIDIA
- g_clear_object (&rdp_server->hwaccel_nvidia);
-#endif /* HAVE_HWACCEL_NVIDIA */
-
if (rdp_server->idle_task)
{
g_source_remove (rdp_server->idle_task);
@@ -242,6 +238,10 @@ grd_rdp_server_dispose (GObject *object)
rdp_server->sessions = NULL;
}
+#ifdef HAVE_HWACCEL_NVIDIA
+ g_clear_object (&rdp_server->hwaccel_nvidia);
+#endif /* HAVE_HWACCEL_NVIDIA */
+
G_OBJECT_CLASS (grd_rdp_server_parent_class)->dispose (object);
}
[
Date Prev][
Date Next] [
Thread Prev][
Thread Next]
[
Thread Index]
[
Date Index]
[
Author Index]