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

Commit 0e10220d authored by Vance Yu's avatar Vance Yu Committed by Automerger Merge Worker
Browse files

Fix the BT settings is crashing after Toggle OFF/ON am: 894aa6dd

parents 27648b1e 894aa6dd
Loading
Loading
Loading
Loading
+5 −6
Original line number Diff line number Diff line
@@ -194,7 +194,8 @@ import java.util.UUID;

    private static final int ADVERTISE_STATE_MAX_SIZE = 5;

    private EvictingQueue<AppAdvertiseStats> mLastAdvertises;
    private final EvictingQueue<AppAdvertiseStats> mLastAdvertises =
            EvictingQueue.create(ADVERTISE_STATE_MAX_SIZE);

    /** Internal list of connected devices **/
    private Set<Connection> mConnections = new HashSet<Connection>();
@@ -244,10 +245,6 @@ import java.util.UUID;
                app = new App(appUid, callback, appName);
                mApps.add(app);
            }

            if (mLastAdvertises == null) {
                mLastAdvertises = EvictingQueue.create(ADVERTISE_STATE_MAX_SIZE);
            }
            return app;
        }
    }
@@ -628,7 +625,9 @@ import java.util.UUID;
            while (i.hasNext()) {
                App entry = i.next();
                entry.unlinkToDeath();
                if (entry.appScanStats != null) {
                    entry.appScanStats.isRegistered = false;
                }
                i.remove();
            }
        }