[PATCH qxl-wddm-dod 04/20] fixup! qxl-wddm-dod: Prepare system thread for rendering

[Date Prev][Date Next][Thread Prev][Thread Next][Date Index][Thread Index]

 



Attempt to close the thread even if we can't create reference
object. This should be really unlikely but we should have a
chance to destroy the thread without causing crashes.
---
 qxldod/QxlDod.cpp | 2 +-
 1 file changed, 1 insertion(+), 1 deletion(-)

diff --git a/qxldod/QxlDod.cpp b/qxldod/QxlDod.cpp
index cba140c..7392399 100755
--- a/qxldod/QxlDod.cpp
+++ b/qxldod/QxlDod.cpp
@@ -5037,11 +5037,11 @@ void QxlDevice::StopPresentThread()
     if (m_PresentThread)
     {
         DbgPrint(TRACE_LEVEL_INFORMATION, ("---> %s\n", __FUNCTION__));
+        PostToWorkerThread(NULL);
         NTSTATUS Status = ObReferenceObjectByHandle(
             m_PresentThread, 0, NULL, KernelMode, &pDispatcherObject, NULL);
         if (NT_SUCCESS(Status))
         {
-            PostToWorkerThread(NULL);
             WaitForObject(pDispatcherObject, NULL);
             ObDereferenceObject(pDispatcherObject);
         }
-- 
2.9.3

_______________________________________________
Spice-devel mailing list
Spice-devel@xxxxxxxxxxxxxxxxxxxxx
https://lists.freedesktop.org/mailman/listinfo/spice-devel




[Index of Archives]     [Linux ARM Kernel]     [Linux ARM]     [Linux Omap]     [Fedora ARM]     [IETF Annouce]     [Security]     [Bugtraq]     [Linux]     [Linux OMAP]     [Linux MIPS]     [ECOS]     [Asterisk Internet PBX]     [Linux API]     [Monitors]