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

Commit 623b46c2 authored by xiamin's avatar xiamin Committed by android-build-merger
Browse files

Merge "new password shouldn't be empty string" am: dd7bd6b1 am: bfb61ed2

am: 7ed29288

Change-Id: I818afc8d73bc0f987ab549a29300cc07b1ef1b89
parents 601beeef 7ed29288
Loading
Loading
Loading
Loading
+9 −3
Original line number Diff line number Diff line
@@ -21,6 +21,7 @@ import android.app.backup.IBackupManager;
import android.os.Bundle;
import android.os.RemoteException;
import android.os.ServiceManager;
import android.text.TextUtils;
import android.util.Log;
import android.view.View;
import android.view.View.OnClickListener;
@@ -96,6 +97,11 @@ Log.i(TAG, "failure; password mismatch?");
    }

    private boolean setBackupPassword(String currentPw, String newPw) {
        // new password can't be empty
        if (TextUtils.isEmpty(newPw)) {
            return false;
        }

        try {
            return mBackupManager.setBackupPassword(currentPw, newPw);
        } catch (RemoteException e) {