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

Commit 34e8e7ae authored by Jaikumar Ganesh's avatar Jaikumar Ganesh Committed by Android Code Review
Browse files

Merge "Add check for null pointer to avoid crash."

parents 1cc03878 b13cbe06
Loading
Loading
Loading
Loading
+1 −1
Original line number Diff line number Diff line
@@ -126,7 +126,7 @@ public class BluetoothOppPreference {

    public void setName(BluetoothDevice remoteDevice, String name) {
        if (V) Log.v(TAG, "Setname for " + remoteDevice + " to " + name);
        if (!name.equals(getName(remoteDevice))) {
        if (name != null && !name.equals(getName(remoteDevice))) {
            Editor ed = mNamePreference.edit();
            ed.putString(remoteDevice.getAddress(), name);
            ed.apply();