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

Commit 8757b285 authored by Jack He's avatar Jack He
Browse files

AdapterProperties: change log level and wording

* When state transition goes from CONNECTED to DISCONNECTED or
  from DISCONNECTED to CONNECTED, it is abnormal, but still falls into
  some normal use case such as sudden disconnection
* This CL changes the log level to warning and reword it to "abnormal"

Bug: 65591907
Test: make, no functional change
Change-Id: I90b801281dde6c5a5c349568dc8e0c4a740b4db6
parent de888022
Loading
Loading
Loading
Loading
+4 −4
Original line number Diff line number Diff line
@@ -454,8 +454,8 @@ class AdapterProperties {
                "PROFILE_CONNECTION_STATE_CHANGE: profile=" + profile + ", device=" + device + ", "
                        + prevState + " -> " + state);
        if (!isNormalStateTransition(prevState, state)) {
            Log.e(TAG,
                    "PROFILE_CONNECTION_STATE_CHANGE: invalid transition for profile=" + profile
            Log.w(TAG,
                    "PROFILE_CONNECTION_STATE_CHANGE: unexpected transition for profile=" + profile
                            + ", device=" + device + ", " + prevState + " -> " + state);
        }
        sendConnectionStateChange(device, profile, state, prevState);
@@ -489,8 +489,8 @@ class AdapterProperties {
                        "ADAPTER_CONNECTION_STATE_CHANGE: " + device + ": " + prevAdapterState
                                + " -> " + newAdapterState);
                if (!isNormalStateTransition(prevState, state)) {
                    Log.e(TAG,
                            "ADAPTER_CONNECTION_STATE_CHANGE: invalid transition for profile="
                    Log.w(TAG,
                            "ADAPTER_CONNECTION_STATE_CHANGE: unexpected transition for profile="
                                    + profile + ", device=" + device + ", " + prevState + " -> "
                                    + state);
                }