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

Commit f74cd68b authored by Android Build Coastguard Worker's avatar Android Build Coastguard Worker
Browse files

Snap for 11902131 from 44212f7a to 24Q3-release

Change-Id: I540317437a776a49c39b23698a50d5ad0427cf5d
parents 4aa7d1c8 44212f7a
Loading
Loading
Loading
Loading
+4 −1
Original line number Diff line number Diff line
@@ -1037,7 +1037,10 @@ class JniScanningCallbacks : ScanningCallbacks {
  void OnTrackAdvFoundLost(AdvertisingTrackInfo track_info) {
    std::shared_lock<std::shared_mutex> lock(callbacks_mutex);
    CallbackEnv sCallbackEnv(__func__);
    if (!sCallbackEnv.valid() || !mScanCallbacksObj) return;
    if (!sCallbackEnv.valid() || !mScanCallbacksObj) {
      log::error("sCallbackEnv not valid or no mScanCallbacksObj.");
      return;
    }

    ScopedLocalRef<jstring> address(
        sCallbackEnv.get(),
+1 −11
Original line number Diff line number Diff line
@@ -282,11 +282,7 @@ public class BluetoothOppService extends ProfileService implements IObexConnecti
                    1);
        }
        setBluetoothOppService(null);
        if (Flags.oppServiceFixIndexOutOfBoundsExceptionInUpdateThread()) {
        stopInternal();
        } else {
            mHandler.sendMessage(mHandler.obtainMessage(STOP_LISTENER));
        }

        setComponentAvailable(OPP_PROVIDER, false);
        setComponentAvailable(INCOMING_FILE_CONFIRM_ACTIVITY, false);
@@ -538,9 +534,6 @@ public class BluetoothOppService extends ProfileService implements IObexConnecti
    @Override
    public void cleanup() {
        Log.v(TAG, "onDestroy");
        if (!Flags.oppServiceFixIndexOutOfBoundsExceptionInUpdateThread()) {
            stopListeners();
        }

        mBatches.clear();
        mShares.clear();
@@ -659,9 +652,6 @@ public class BluetoothOppService extends ProfileService implements IObexConnecti
                        break;
                    case BluetoothAdapter.STATE_TURNING_OFF:
                        Log.v(TAG, "Bluetooth state changed: STATE_TURNING_OFF");
                        if (!Flags.oppServiceFixIndexOutOfBoundsExceptionInUpdateThread()) {
                            mHandler.sendMessage(mHandler.obtainMessage(STOP_LISTENER));
                        }
                        break;
                }
            }
+0 −6
Original line number Diff line number Diff line
@@ -22,7 +22,6 @@ import static android.content.pm.PackageManager.DONT_KILL_APP;
import android.content.ComponentName;
import android.content.ContentValues;
import android.content.Context;
import android.platform.test.flag.junit.SetFlagsRule;

import androidx.test.annotation.UiThreadTest;
import androidx.test.filters.SmallTest;
@@ -30,7 +29,6 @@ import androidx.test.platform.app.InstrumentationRegistry;
import androidx.test.runner.AndroidJUnit4;

import com.android.bluetooth.btservice.AdapterService;
import com.android.bluetooth.flags.Flags;

import org.junit.Rule;
import org.junit.Test;
@@ -41,7 +39,6 @@ import org.mockito.junit.MockitoRule;
@SmallTest
@RunWith(AndroidJUnit4.class)
public class BluetoothOppServiceCleanupTest {
    @Rule public final SetFlagsRule mSetFlagsRule = new SetFlagsRule();
    @Rule public MockitoRule mockitoRule = MockitoJUnit.rule();

    private final Context mTargetContext =
@@ -50,9 +47,6 @@ public class BluetoothOppServiceCleanupTest {
    @Test
    @UiThreadTest
    public void testStopAndCleanup() {
        mSetFlagsRule.enableFlags(
                Flags.FLAG_OPP_SERVICE_FIX_INDEX_OUT_OF_BOUNDS_EXCEPTION_IN_UPDATE_THREAD);

        AdapterService adapterService = new AdapterService(mTargetContext);

        // Don't need to disable again since it will be handled in OppService.stop
+10 −0
Original line number Diff line number Diff line
@@ -196,3 +196,13 @@ flag {
        purpose: PURPOSE_BUGFIX
    }
}

flag {
    name: "sec_dont_clear_keys_on_encryption_err"
    namespace: "bluetooth"
    description: "Do not clear security record on encryption error"
    bug: "342521414"
    metadata {
        purpose: PURPOSE_BUGFIX
    }
}
+0 −11
Original line number Diff line number Diff line
@@ -17,14 +17,3 @@ flag {
        purpose: PURPOSE_BUGFIX
    }
}

flag {
    name: "opp_service_fix_index_out_of_bounds_exception_in_update_thread"
    namespace: "bluetooth"
    description: "Fix IndexOutOfBoundsException which happens in OPP service's UpdateThread"
    bug: "326135849"
    metadata {
        purpose: PURPOSE_BUGFIX
    }
}
Loading