Network: Check parameter for NULL in isMmsRequest method

It's the NullPointerException which causes the third part
application can't work normally. It happens when the third
part application calls execute in AndroidHttpClient.java.
The parameter may null when calling checkMmsSendPermission.

Add extra judgement to avoid NullPointerException for fixing
this issue.

CRs-Fixed: 584775

Change-Id: I1db5160952f1effeff7c35b10ae26656dfe476d8
(cherry picked from commit 86381b701e7ae9389a5986933061d42413484187)
[ActivityManager] Finish the failed-to-pause activity

Symptom:
In some scenario, the mPausingActivity may be replaced by other activity.
When previous activity paused, the completePausedLocked() won't be invoked
because it is no longer the mPausingActivity. If the activity is also
pending to finish, it would never be done because the activity kept in
PAUSING state. Since the activity's window also remain visible and is
above on Wallpaper, user would see it when back to home.

Solution:
Finish the failed-to-pause activity if the activity is pending to finish

A Real Case:
(1) Screen turn off
(2) The top activity T1 crashed
(3) When finish activity T1, the next top activity T2 will be scheduled
    to resume and pause (due to screen off).
(4) The activity T2 is also set to finishing due to T1 crashed.
(5) Before T2 paused and before paused timeout occurs, there has a new
    process started which brings up the next top activity T3 to resume
    and pause. So the pausing activity is now replaced.
(6) When activity T2 paused, it cannot completed the pause operation.
    T2 will remain in PAUSING and finishing state with its window visible.
    The process won't be killed because the oomadj stays at 1 (Visible).

Change-Id: Ib10fded891b21c774b26a93071c717fa50516e22
(cherry picked from commit 6383dfe4dc882190a698981b33e0075e6c455a30)
ActivityManagerService: Penalise large apps going to background

Large applications (PSS more than a given threshold) when closed are
penalised with higher ADJ. Now, they will be more prone to be killed by
lowmemorykiller during memory pressure levels. This ensures better app
concurrency and improved subsequent latencies as it leaves some more room
for other smaller bg apps to be alive

Change-Id: I448fa12f55370949b22075595cd75b9c29e5d4b5
(cherry picked from commit 65b15e59ab09697f61939e4e4b933d126b9ad21a)
lowmemorykiller: Overwrite LMK parameters for low-tier devices

LMK parameters calculated by default algorithm were not optimal for
low-tier devices. Values mentioned here were well tested and
evaluated w.r.t memory and performance for such setups.

Change-Id: I40ed92d204aae6e758028ea1e9bd4ec7226dbe2b
(cherry picked from commit 38e8cd4b88a6a13a60b68a332bae57dd2f8f77e4)
SystemUI: Update user name timely when delete the user contact

The user name isn't updated timely when delete the user
contact in contacts.

Update the user name timely when receive the user info
changed event.

CRs-Fixed: 673195

Change-Id: I30d694b0f4486cb00f26542ef3bc54b5825373c7
(cherry picked from commit bbccbfa63783f8efd8f561621c7bee8b6061e843)