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

Commit 5d07e5bf authored by android-build-team Robot's avatar android-build-team Robot
Browse files

Snap for 5647767 from 40a96736 to qt-c2f2-release

Change-Id: Icef189c7acf6f1863ca236b11ccd450be9573f20
parents 469744e6 40a96736
Loading
Loading
Loading
Loading
+2 −0
Original line number Diff line number Diff line
@@ -101,6 +101,8 @@ public abstract class CallTracker extends Handler {

    protected abstract void handlePollCalls(AsyncResult ar);

    protected abstract Phone getPhone();

    protected Connection getHoConnection(DriverCall dc) {
        for (Connection hoConn : mHandoverConnections) {
            log("getHoConnection - compare number: hoConn= " + hoConn.toString());
+15 −11
Original line number Diff line number Diff line
@@ -96,8 +96,6 @@ public class CarrierKeyDownloadManager extends Handler {
    private static final String SEPARATOR = ":";

    private static final String JSON_CERTIFICATE = "certificate";
    // This is a hack to accommodate certain Carriers who insists on using the public-key
    // field to store the certificate. We'll just use which-ever is not null.
    private static final String JSON_CERTIFICATE_ALTERNATE = "public-key";
    private static final String JSON_TYPE = "key-type";
    private static final String JSON_IDENTIFIER = "key-identifier";
@@ -111,7 +109,6 @@ public class CarrierKeyDownloadManager extends Handler {

    private static final int[] CARRIER_KEY_TYPES = {TelephonyManager.KEY_TYPE_EPDG,
            TelephonyManager.KEY_TYPE_WLAN};
    private static final int UNINITIALIZED_KEY_TYPE = -1;

    private final Phone mPhone;
    private final Context mContext;
@@ -451,20 +448,27 @@ public class CarrierKeyDownloadManager extends Handler {
            JSONArray keys = jsonObj.getJSONArray(JSON_CARRIER_KEYS);
            for (int i = 0; i < keys.length(); i++) {
                JSONObject key = keys.getJSONObject(i);
                // This is a hack to accommodate certain carriers who insist on using the public-key
                // field to store the certificate. We'll just use which-ever is not null.
                // Support both "public-key" and "certificate" String property.
                // "certificate" is a more accurate description, however, the 3GPP draft spec
                // S3-170116, "Privacy Protection for EAP-AKA" section 4.3 mandates the use of
                // "public-key".
                String cert = null;
                if (key.has(JSON_CERTIFICATE)) {
                    cert = key.getString(JSON_CERTIFICATE);
                } else {
                    cert = key.getString(JSON_CERTIFICATE_ALTERNATE);
                }
                // The 3GPP draft spec 3GPP draft spec S3-170116, "Privacy Protection for EAP-AKA"
                // section 4.3, does not specify any key-type property. To be compatible with these
                // networks, the logic defaults to WLAN type if not specified.
                int type = TelephonyManager.KEY_TYPE_WLAN;
                if (key.has(JSON_TYPE)) {
                    String typeString = key.getString(JSON_TYPE);
                int type = UNINITIALIZED_KEY_TYPE;
                if (typeString.equals(JSON_TYPE_VALUE_WLAN)) {
                    type = TelephonyManager.KEY_TYPE_WLAN;
                } else if (typeString.equals(JSON_TYPE_VALUE_EPDG)) {
                    if (typeString.equals(JSON_TYPE_VALUE_EPDG)) {
                        type = TelephonyManager.KEY_TYPE_EPDG;
                    } else if (!typeString.equals(JSON_TYPE_VALUE_WLAN)) {
                        Log.e(LOG_TAG, "Invalid key-type specified: " + typeString);
                    }
                }
                String identifier = key.getString(JSON_IDENTIFIER);
                ByteArrayInputStream inStream = new ByteArrayInputStream(cert.getBytes());
+11 −4
Original line number Diff line number Diff line
@@ -506,10 +506,9 @@ public abstract class Connection {
     *
     * @hide
     */
    public void setEmergencyCallInfo() {
        Call call = getCall();
        if (call != null) {
            Phone phone = call.getPhone();
    public void setEmergencyCallInfo(CallTracker ct) {
        if (ct != null) {
            Phone phone = ct.getPhone();
            if (phone != null) {
                EmergencyNumberTracker tracker = phone.getEmergencyNumberTracker();
                if (tracker != null) {
@@ -517,9 +516,17 @@ public abstract class Connection {
                    if (num != null) {
                        mIsEmergencyCall = true;
                        mEmergencyNumberInfo = num;
                    } else {
                        Rlog.e(TAG, "setEmergencyCallInfo: emergency number is null");
                    }
                } else {
                    Rlog.e(TAG, "setEmergencyCallInfo: emergency number tracker is null");
                }
            } else {
                Rlog.e(TAG, "setEmergencyCallInfo: phone is null");
            }
        } else {
            Rlog.e(TAG, "setEmergencyCallInfo: call tracker is null");
        }
    }

+1 −0
Original line number Diff line number Diff line
@@ -1748,6 +1748,7 @@ public class GsmCdmaCallTracker extends CallTracker {
    }

    @UnsupportedAppUsage
    @Override
    public GsmCdmaPhone getPhone() {
        return mPhone;
    }
+2 −2
Original line number Diff line number Diff line
@@ -136,7 +136,7 @@ public class GsmCdmaConnection extends Connection {
        mHandler = new MyHandler(mOwner.getLooper());

        mAddress = dc.number;
        setEmergencyCallInfo();
        setEmergencyCallInfo(mOwner);

        mIsIncoming = dc.isMT;
        mCreateTime = System.currentTimeMillis();
@@ -179,7 +179,7 @@ public class GsmCdmaConnection extends Connection {

        mAddress = PhoneNumberUtils.extractNetworkPortionAlt(dialString);
        if (isEmergencyCall) {
            setEmergencyCallInfo();
            setEmergencyCallInfo(mOwner);
        }

        mPostDialString = PhoneNumberUtils.extractPostDialPortion(dialString);
Loading