wait for background thread before free()ing koptcontext
This should prevent freeing resources that are actually in use in a background thread.
This commit is contained in:
1 parent
9b5ff4ca41
commit
f9f97163e8
1 file changed
+1
@@ -23,6 +23,7 @@ local ContextCacheItem = CacheItem:new{}
|
||||
|
||||
function ContextCacheItem:onFree()
|
||||
if self.kctx.free then
|
||||
KoptInterface:waitForContext(self.kctx)
|
||||
DEBUG("free koptcontext", self.kctx)
|
||||
self.kctx:free()
|
||||
end
|
||||
|
||||
Reference in new issue
Block a user