aboutsummaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorAshley Hughes <spirit.returned@gmail.com>2013-09-17 18:31:02 +0100
committerAshley Hughes <spirit.returned@gmail.com>2013-09-17 18:31:02 +0100
commit32b2711e6184721ceb74c4220b86295f0e51e5ad (patch)
tree13993a9b6ee262481b3045a83baa3f058d884e21
parentb4382db2638a7b29c95bfb8b442ca9f7644b9d8c (diff)
downloadopen-keychain-32b2711e6184721ceb74c4220b86295f0e51e5ad.tar.gz
open-keychain-32b2711e6184721ceb74c4220b86295f0e51e5ad.tar.bz2
open-keychain-32b2711e6184721ceb74c4220b86295f0e51e5ad.zip
null check
-rw-r--r--OpenPGP-Keychain/src/org/sufficientlysecure/keychain/pgp/PgpImportExport.java3
1 files changed, 2 insertions, 1 deletions
diff --git a/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/pgp/PgpImportExport.java b/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/pgp/PgpImportExport.java
index dac9c9b11..d7ab5d8fe 100644
--- a/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/pgp/PgpImportExport.java
+++ b/OpenPGP-Keychain/src/org/sufficientlysecure/keychain/pgp/PgpImportExport.java
@@ -272,7 +272,8 @@ public class PgpImportExport {
}
newPubRing = PGPPublicKeyRing.insertPublicKey(newPubRing, key);
}
- ProviderHelper.saveKeyRing(mContext, newPubRing);
+ if (newPubRing != null)
+ ProviderHelper.saveKeyRing(mContext, newPubRing);
// TODO: remove status returns, use exceptions!
status = Id.return_value.ok;
}