diff options
| author | 2023-08-30 19:25:18 +0000 | |
|---|---|---|
| committer | 2023-08-30 19:25:18 +0000 | |
| commit | a7a99191cc3904807368c275c69bc75bed7fef76 (patch) | |
| tree | 3523fb9929caaaf6761632abce57d45febfb7158 | |
| parent | b68a7b78226be7fe879c79c5b43d071f26262b92 (diff) | |
| parent | 5fdfd60ff76714e6978e9da87ec4321cb98b2ee7 (diff) | |
Merge "Fix possible leaks in CanvasContext HintSessionWrapper" into udc-dev
| -rw-r--r-- | libs/hwui/renderthread/HintSessionWrapper.cpp | 5 |
1 files changed, 5 insertions, 0 deletions
diff --git a/libs/hwui/renderthread/HintSessionWrapper.cpp b/libs/hwui/renderthread/HintSessionWrapper.cpp index 814ac4d90028..30e472a79926 100644 --- a/libs/hwui/renderthread/HintSessionWrapper.cpp +++ b/libs/hwui/renderthread/HintSessionWrapper.cpp @@ -93,8 +93,13 @@ HintSessionWrapper::HintSessionWrapper(pid_t uiThreadId, pid_t renderThreadId) : mUiThreadId(uiThreadId), mRenderThreadId(renderThreadId) {} HintSessionWrapper::~HintSessionWrapper() { + if (mHintSessionFuture.valid()) { + mHintSession = mHintSessionFuture.get(); + } if (mHintSession) { gAPH_closeSessionFn(mHintSession); + mSessionValid = true; + mHintSession = nullptr; } } |