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

Commit de564bd8 authored by Treehugger Robot's avatar Treehugger Robot Committed by Automerger Merge Worker
Browse files

Merge "NIAP: Make sure that call getOrCreateSecretKey once at a time" am:...

Merge "NIAP: Make sure that call getOrCreateSecretKey once at a time" am: a5c7c45b am: 067d0968 am: bdf4dbd2

Original change: https://android-review.googlesource.com/c/platform/packages/apps/Bluetooth/+/1355677

Change-Id: I84c2d691ecbd3256df3ccfc004d313dfb2a41d6e
parents 992480bb bdf4dbd2
Loading
Loading
Loading
Loading
+2 −1
Original line number Diff line number Diff line
@@ -797,7 +797,8 @@ public class BluetoothKeystoreService {
        return keyStore;
    }

    private SecretKey getOrCreateSecretKey() {
    // The getOrGenerate semantic on keystore is not thread safe, need to synchronized it.
    private synchronized SecretKey getOrCreateSecretKey() {
        SecretKey secretKey = null;
        try {
            KeyStore keyStore = getKeyStore();