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

Commit 583e8058 authored by Eric Laurent's avatar Eric Laurent Committed by Gerrit Code Review
Browse files

Merge "[HWAsan Test]fix use-after-free bug"

parents e40c6041 0e1f56e2
Loading
Loading
Loading
Loading
+1 −0
Original line number Original line Diff line number Diff line
@@ -1721,6 +1721,7 @@ void AudioPolicyService::UidPolicy::updateUidLocked(std::unordered_map<uid_t,
}
}


bool AudioPolicyService::UidPolicy::isA11yOnTop() {
bool AudioPolicyService::UidPolicy::isA11yOnTop() {
    Mutex::Autolock _l(mLock);
    for (const auto &uid : mCachedUids) {
    for (const auto &uid : mCachedUids) {
        if (!isA11yUid(uid.first)) {
        if (!isA11yUid(uid.first)) {
            continue;
            continue;
+2 −2
Original line number Original line Diff line number Diff line
@@ -475,8 +475,8 @@ private:
        Mutex mLock;
        Mutex mLock;
        ActivityManager mAm;
        ActivityManager mAm;
        bool mObserverRegistered = false;
        bool mObserverRegistered = false;
        std::unordered_map<uid_t, std::pair<bool, int>> mOverrideUids;
        std::unordered_map<uid_t, std::pair<bool, int>> mOverrideUids GUARDED_BY(mLock);
        std::unordered_map<uid_t, std::pair<bool, int>> mCachedUids;
        std::unordered_map<uid_t, std::pair<bool, int>> mCachedUids GUARDED_BY(mLock);
        std::vector<uid_t> mAssistantUids;
        std::vector<uid_t> mAssistantUids;
        std::vector<uid_t> mActiveAssistantUids;
        std::vector<uid_t> mActiveAssistantUids;
        std::vector<uid_t> mA11yUids;
        std::vector<uid_t> mA11yUids;