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

Commit e5084d86 authored by Guojing Yuan's avatar Guojing Yuan
Browse files

[CDM] Disk IO must be run on a separate thread.

Fix: 378913052
Test: CTS
Flag: EXEMPT bugfix
Change-Id: I24991514dfea16c3a70aa742c3305562a26a296a
parent 44102648
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -108,6 +108,8 @@ import java.io.FileDescriptor;
import java.io.PrintWriter;
import java.util.Collection;
import java.util.List;
import java.util.concurrent.ExecutorService;
import java.util.concurrent.Executors;

@SuppressLint("LongLogTag")
public class CompanionDeviceManagerService extends SystemService {
@@ -225,7 +227,8 @@ public class CompanionDeviceManagerService extends SystemService {
        if (associations.isEmpty()) return;

        mCompanionExemptionProcessor.updateAtm(userId, associations);
        mCompanionExemptionProcessor.updateAutoRevokeExemptions();
        ExecutorService executor = Executors.newSingleThreadExecutor();
        executor.execute(mCompanionExemptionProcessor::updateAutoRevokeExemptions);
    }

    @Override