In VuklanManager make sure we have a valid semaphore context before destroying it.
If errors occured during finishFrame that caused us to not have a semaphore or possibly destroy the semaphore early we will end up with a null mDestroySemaphoreContext in swapBuffers which we tried to destroy unconditionally. I haven't repro'd the connected bug, but based on the crash stack this seems like the likely cause. Test: manual code inspection and build. Bug: 191950033 Change-Id: I0fbd33edff3552b91b980da9e3b2c45bc52a2dd0
This commit is contained in:
@@ -579,7 +579,9 @@ void VulkanManager::swapBuffers(VulkanSurface* surface, const SkRect& dirtyRect)
|
||||
std::lock_guard<std::mutex> lock(mGraphicsQueueMutex);
|
||||
mQueueWaitIdle(mGraphicsQueue);
|
||||
}
|
||||
destroy_semaphore(mDestroySemaphoreContext);
|
||||
if (mDestroySemaphoreContext) {
|
||||
destroy_semaphore(mDestroySemaphoreContext);
|
||||
}
|
||||
|
||||
surface->presentCurrentBuffer(dirtyRect, fenceFd);
|
||||
mSwapSemaphore = VK_NULL_HANDLE;
|
||||
|
||||
Reference in New Issue
Block a user