mirror of
https://github.com/baldurk/renderdoc.git
synced 2026-10-16 00:59:22 +00:00
Wait for the socket thread to finish when unloading, close the open socket.
The Android loader dlopens a layer twice, so if the layer did not clean up properly the first time it is unloaded then we will fail to open a socket on the default port 38920 during the second dlopen.
This commit is contained in:
1 parent
333d8e16b1
commit
cc3cc1f392
2 files changed
+3
No files matched your search
@@ -320,6 +320,7 @@ RenderDoc::~RenderDoc()
|
||||
{
|
||||
m_RemoteServerThreadShutdown = true;
|
||||
// don't join, just close the thread, as we can't wait while in the middle of module unloading
|
||||
Threading::Sleep(50);
|
||||
Threading::CloseThread(m_RemoteThread);
|
||||
m_RemoteThread = 0;
|
||||
}
|
||||
|
||||
@@ -353,6 +353,8 @@ void RenderDoc::RemoteAccessServerThread(void *s)
|
||||
Threading::CloseThread(clientThread);
|
||||
clientThread = 0;
|
||||
|
||||
SAFE_DELETE(sock);
|
||||
|
||||
Threading::ReleaseModuleExitThread();
|
||||
}
|
||||
|
||||
|
||||
Reference in new issue
Block a user