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

Commit 4fdc57b9 authored by Sanket Padawe's avatar Sanket Padawe
Browse files

Fix crash in ApnContext after EVENT_DISCONNECT_DONE event in DcTracker.

+ This issue is fixed by setting non null reason for ApnContext from
DcTracker.
+ Minor fix over ag/1112902 which actually helped figure out that we were
passing null reason code to ApnContext.

Bug: 29346477
Change-Id: I40c007de804bd5b10b28736c3012c6c88de8811e
parent 12562747
Loading
Loading
Loading
Loading
+2 −2
Original line number Diff line number Diff line
@@ -343,8 +343,8 @@ public class ApnContext {
     * @return True if it is fast retry reason, otherwise false.
     */
    private boolean isFastRetryReason() {
        return mReason.equals(Phone.REASON_NW_TYPE_CHANGED) ||
                mReason.equals(Phone.REASON_APN_CHANGED);
        return Phone.REASON_NW_TYPE_CHANGED.equals(mReason) ||
                Phone.REASON_APN_CHANGED.equals(mReason);
    }

    /** Check if the data call is in connected or connecting state.
+2 −2
Original line number Diff line number Diff line
@@ -3020,7 +3020,7 @@ public class DcTracker extends Handler {
         * to clean data connections.
         */
        if (!mInternalDataEnabled) {
            cleanUpAllConnections(null);
            cleanUpAllConnections(Phone.REASON_DATA_DISABLED);
        }

    }
@@ -4127,7 +4127,7 @@ public class DcTracker extends Handler {
            } else {
                sendOnComplete = false;
                log("onSetInternalDataEnabled: changed to disabled, cleanUpAllConnections");
                cleanUpAllConnections(null, onCompleteMsg);
                cleanUpAllConnections(Phone.REASON_DATA_DISABLED, onCompleteMsg);
            }
        }