CyanogenMod com.android.phone crashing – an unlikely APN fix for the NullPointerException in the telephony stack

Currently, I have a T-Mobile branded Samsung Galaxy S4 (SGH-M919) and until this past weekend I was running CyanogenMod 11 (the M9 snapshot) on it. I was having one minor problem with it, and that was that all-too-often the artist and track information from my music stream would not be sent via Bluetooth. I hadn’t updated because if the majority of things are running smoothly, why test fate? Anyway, a few days ago I took the plunge and updated to the M12 snapshot via the CM Updater.

Almost immediately I ran into a big problem. Every so often (seemingly randomly), I would get the alert that “Unfortunately, com.android.phone” had stopped. Worse yet, when that happened, I would lose mobile connectivity on any voice call. If I was in a voice call, the connection would drop. If I wasn’t in a call, I would be unable to receive or dial out for some time. Clearly, this was a huge problem since… well… one of the primary foci of a mobile is to make and receive voice calls.

Thinking that it was a problem with flashing the new ROM from CM Updater, I tried manually flashing the M12 snapshot. When that didn’t work, I tried a bunch of other things as well:

Unfortunately, all of these things got me nowhere. The problem was still occurring, and I couldn’t figure out what was happening. At first I was thinking that there was a hardware problem, but the Java stack trace indicated otherwise:

[CRASH] com.android.phone threw java.lang.NullPointerException
at android.telephony.SmsMessage.getTimestampMillis(SmsMesssage.java:607)

After all of those troubleshooting steps, though, CyanogenMod 12 revealed something to me that I hadn’t seen in the stack trace before:

com.android.mms.service

Noticing the MMS portion of that error made me think to check the APN settings for the device. What I found is that there were some slight problems. Below is what the settings were “out of the box” in CyanogenMod for the jfltetmo/jflte (which is the Samsung Galaxy S4):

Name: T-Mobile US LTE
APN: fast.t-mobile.com
Proxy: Not set
Port: Not set
Username: none
Password: **** (yes, four asterisks)
Server: * (yes, just as asterisk)
MMSC: http://mms.msg.eng.t-mobile.com/mms/wapenc
MMS Proxy: Not set
MMS Port: Not set
MMC: 310
MNC: 260
Authentication type: Not set
APN type: default,supl,mms
APN protocol: IPv4
APN roaming protocol: IPv4
Bearer: Unspecified
MVNO type: None

HOWEVER, they should be (the changes that I had to make are in red; you may need to change others to match the ones below):

Name: T-Mobile US LTE
APN: fast.t-mobile.com
Proxy: Not set
Port: Not set
Username: none
Password: Not set
Server: Not set
MMSC: http://mms.msg.eng.t-mobile.com/mms/wapenc
MMS Proxy: Not set
MMS Port: 80
MMC: 310
MNC: 260
Authentication type: Not set
APN type: default,supl,mms
APN protocol: IPv4
APN roaming protocol: IPv4
Bearer: Unspecified
MVNO type: None

After making those changes and setting them in the APN, voilà! No more message about com.android.phone crashing with reference to com.android.mms.service.

If you are experiencing the same problem, I hope that you see this post before going through WAY too may troubleshooting steps whilst overlooking the smaller, more likely problems. Let us not forget Ockham’s Razor—given equal circumstances, the simplest solution tends to be the correct one.

Cheers,
Zach

3 comments

  1. Thank you, thank you, thank you, thank you, etc.. Brilliant fix! My new handset (supplied running Cyanogen O/S, as opposed to a Cyanogen mod Android device) started doing this very thing today and has now decided, following my following your advice, to behave itself. The weird thing was that it was only doing this when the Vodafone SIM was selected and active, when I switched to the NowMobile SIM (uses the EE network), it didn’t do it although the settings in APN menu were the same as those for the other SIM, but with the appropriate differences in the detail.

    So it’s all good now and for that, I shall be eternally grateful as I detest being pwned by my gadgetry.

    Cheers,

    Fat Al, from the sunny Wight.

      • Zach on Wednesday, 30 March 2016 at 11:07
        Author
      • Reply

      Hi Alan,

      Glad that the article helped you. 🙂

      Cheers,
      Zach

    • JoJo1973 on Friday, 20 March 2015 at 18:30
    • Reply

    Hopefully you’ve reported the issue..!

Leave a Reply

Your email address will not be published.