commit | 2f359c1ddfd33449f5219f70622f21049c15d895 | [log] [tgz] |
---|---|---|
author | Matt Buckley <mattbuckley@google.com> | Thu Aug 24 15:56:46 2023 +0000 |
committer | Android Build Coastguard Worker <android-build-coastguard-worker@google.com> | Wed Aug 30 17:54:11 2023 +0000 |
tree | 2a4ae79951c8c57bbd06f919ef286ebab999ea8a | |
parent | 5fa41f5201dde5f7406e0079a4b21402190fe9b8 [diff] [blame] |
Fix possible leaks in CanvasContext HintSessionWrapper Ensure the mHintSessionFuture is accounted for correctly in the destructor. Bug: b/297230599 Test: manual (cherry picked from commit ac620f64a32500890007b0b405ca72405d6db41e) (cherry picked from https://googleplex-android-review.googlesource.com/q/commit:e4b73a7aa058be845d3ee2433b8da99fc524d7c1) Merged-In: Idcbd0f2ba87290f090d693f0a64cb46fe8270b95 Change-Id: Idcbd0f2ba87290f090d693f0a64cb46fe8270b95
diff --git a/libs/hwui/renderthread/CanvasContext.cpp b/libs/hwui/renderthread/CanvasContext.cpp index 16b35ff..504dfaa 100644 --- a/libs/hwui/renderthread/CanvasContext.cpp +++ b/libs/hwui/renderthread/CanvasContext.cpp
@@ -193,6 +193,7 @@ void CanvasContext::setSurface(ANativeWindow* window, bool enableTimeout) { ATRACE_CALL(); + startHintSession(); if (window) { mNativeSurface = std::make_unique<ReliableSurface>(window); mNativeSurface->init();