diff options
author | JesperBK <jesper.b.kjaer@gmail.com> | 2015-03-23 11:17:01 +0100 |
---|---|---|
committer | JesperBK <jesper.b.kjaer@gmail.com> | 2015-03-23 11:17:01 +0100 |
commit | 5bdac11ef84d9ce5990536110280d7857165cf10 (patch) | |
tree | 9fe64336c8d5c5f79d107c0e89c81f6c229e4e4f /OpenKeychain/src/main/java/org/sufficientlysecure/keychain | |
parent | c7efaacc9d1abc03036625b29961b5dad2672c44 (diff) | |
download | open-keychain-5bdac11ef84d9ce5990536110280d7857165cf10.tar.gz open-keychain-5bdac11ef84d9ce5990536110280d7857165cf10.tar.bz2 open-keychain-5bdac11ef84d9ce5990536110280d7857165cf10.zip |
Fixed issue where setting a passphrase to null later causes a NullPointerException.
Diffstat (limited to 'OpenKeychain/src/main/java/org/sufficientlysecure/keychain')
-rw-r--r-- | OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EncryptTextActivity.java | 4 |
1 files changed, 3 insertions, 1 deletions
diff --git a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EncryptTextActivity.java b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EncryptTextActivity.java index c800153ae..dd09e62c3 100644 --- a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EncryptTextActivity.java +++ b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/ui/EncryptTextActivity.java @@ -136,7 +136,9 @@ public class EncryptTextActivity extends EncryptActivity implements EncryptActiv @Override public void setPassphrase(Passphrase passphrase) { - mPassphrase.removeFromMemory(); + if (mPassphrase != null) { + mPassphrase.removeFromMemory(); + } mPassphrase = passphrase; } |