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

Commit 527b36d0 authored by Koushik Dutta's avatar Koushik Dutta
Browse files

Fix Whisperpush and Voice+ when using the new Hangouts.

Change-Id: I1ae96354e8d5679d1e7b781875081cec08108691
parent ad87897f
Loading
Loading
Loading
Loading
+8 −0
Original line number Diff line number Diff line
@@ -158,6 +158,14 @@ public class SmsMessage {
            wrappedMessage = com.android.internal.telephony.gsm.SmsMessage.createFromPdu(pdu);
        }

        // Hangouts, and some other bad citizens, are using this deprecated API call.
        // Make sure that WhisperPush and Voice+ integration properly work,
        // as this may be a synthetic message.
        if (wrappedMessage == null) {
            // returns null if it is not synthetic. (likely malformed)
            wrappedMessage = com.android.internal.telephony.SyntheticSmsMessage.createFromPdu(pdu);
        }

        return new SmsMessage(wrappedMessage);
    }