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

Commit 2b3361e9 authored by Jakub Pawlowski's avatar Jakub Pawlowski Committed by android-build-merger
Browse files

Merge "Fix null settings in AdvertiseCallback.onStartSuccess" am: 52d4a478 am: 3aa1b1e8

am: 12f66250

Change-Id: Ida31e833b8b818200177ef0b429f9e02d0b8f0ac
parents 14f8387d 12f66250
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -137,7 +137,7 @@ class AdvertiseManager {
        }
    }

    private AdvertiseClient getAdvertiseClient(int advertiserId) {
    public AdvertiseClient getAdvertiseClient(int advertiserId) {
        for (AdvertiseClient client : mAdvertiseClients) {
            if (client.advertiserId == advertiserId) {
                return client;
+3 −1
Original line number Diff line number Diff line
@@ -1193,8 +1193,10 @@ public class GattService extends ProfileService {
        AdvertiserMap.App app = mAdvertiserMap.getById(advertiserId);
        if (app != null) {
            if (status == 0) {
                AdvertiseClient client = mAdvertiseManager.getAdvertiseClient(advertiserId);
                AdvertiseSettings settings = (client == null) ? null : client.settings;
                app.callback.onMultiAdvertiseCallback(AdvertiseCallback.ADVERTISE_SUCCESS,
                        true, null);
                        true, settings);
            } else {
                app.callback.onMultiAdvertiseCallback(
                        AdvertiseCallback.ADVERTISE_FAILED_INTERNAL_ERROR, true, null);