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

Commit 2ac1380d authored by Tej Singh's avatar Tej Singh
Browse files

Revert "Revert "Logging: Bluetooth Enabled""

This reverts commit 5c01a03a.

Reason for revert: The dummy StatsLog class was merged into stage-aosp-master and oc-mr1-dev-plus-aosp, which were the branches that broke initially.

Change-Id: Iab9bac487d845db0ba70b2622679523604b4944e
parent 5c01a03a
Loading
Loading
Loading
Loading
+6 −0
Original line number Diff line number Diff line
@@ -60,6 +60,7 @@ import android.os.UserManagerInternal.UserRestrictionsListener;
import android.provider.Settings;
import android.provider.Settings.SettingNotFoundException;
import android.util.Slog;
import android.util.StatsLog;

import com.android.internal.R;
import com.android.internal.util.DumpUtils;
@@ -2154,6 +2155,11 @@ class BluetoothManagerService extends IBluetoothManager.Stub {
            mActiveLogs.add(
                    new ActiveLog(reason, packageName, enable, System.currentTimeMillis()));
        }

        int state = enable ? StatsLog.BLUETOOTH_ENABLED_STATE_CHANGED__STATE__ENABLED :
                             StatsLog.BLUETOOTH_ENABLED_STATE_CHANGED__STATE__DISABLED;
        StatsLog.write_non_chained(StatsLog.BLUETOOTH_ENABLED_STATE_CHANGED,
                Binder.getCallingUid(), null, state, reason, packageName);
    }

    private void addCrashLog() {