Donate to e Foundation | Murena handsets with /e/OS | Own a part of Murena! Learn more

Commit 409e5a07 authored by Gloria Wang's avatar Gloria Wang
Browse files

Fix a memory leak in the Forward Lock plugin.

For bug 4770217.

Change-Id: I14f4d4ead524c661e68a20738e7a50e4d8fd92ea
parent 50b0f02d
Loading
Loading
Loading
Loading
+13 −0
Original line number Diff line number Diff line
@@ -512,6 +512,19 @@ status_t FwdLockEngine::onCloseDecryptSession(int uniqueId,
        }
    }

    if (NULL != decryptHandle) {
        if (NULL != decryptHandle->decryptInfo) {
            delete decryptHandle->decryptInfo;
            decryptHandle->decryptInfo = NULL;
        }

        decryptHandle->copyControlVector.clear();
        decryptHandle->extendedData.clear();

        delete decryptHandle;
        decryptHandle = NULL;
    }

    LOGV("FwdLockEngine::onCloseDecryptSession Exit");
    return result;
}