aboutsummaryrefslogtreecommitdiffstats
path: root/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/PgpDecryptVerify.java
diff options
context:
space:
mode:
authorVincent Breitmoser <valodim@mugenguild.com>2015-02-17 18:43:43 +0100
committerVincent Breitmoser <valodim@mugenguild.com>2015-02-17 18:43:43 +0100
commitbb30cb540123577e87c313f71b460482be3e287c (patch)
treeddc24e6e1dae163aa503578cfc6f2dffb757f3ed /OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/PgpDecryptVerify.java
parent260ffdf588a0fcd6faef7cc5cf026b9c4bba85be (diff)
downloadopen-keychain-bb30cb540123577e87c313f71b460482be3e287c.tar.gz
open-keychain-bb30cb540123577e87c313f71b460482be3e287c.tar.bz2
open-keychain-bb30cb540123577e87c313f71b460482be3e287c.zip
fix comments and some warnings in PgpDecryptVerify
Diffstat (limited to 'OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/PgpDecryptVerify.java')
-rw-r--r--OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/PgpDecryptVerify.java13
1 files changed, 4 insertions, 9 deletions
diff --git a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/PgpDecryptVerify.java b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/PgpDecryptVerify.java
index e7ab05261..2ee923e42 100644
--- a/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/PgpDecryptVerify.java
+++ b/OpenKeychain/src/main/java/org/sufficientlysecure/keychain/pgp/PgpDecryptVerify.java
@@ -160,9 +160,6 @@ public class PgpDecryptVerify extends BaseOperation {
/**
* If detachedSignature != null, it will be used exclusively to verify the signature
- *
- * @param detachedSignature
- * @return
*/
public Builder setDetachedSignature(byte[] detachedSignature) {
mDetachedSignature = detachedSignature;
@@ -540,7 +537,7 @@ public class PgpDecryptVerify extends BaseOperation {
PGPLiteralData literalData = (PGPLiteralData) dataChunk;
- // this is the encrypted size so if we enable compression this value is wrong!
+ // reported size may be null if partial packets are involved (highly unlikely though)
Long originalSize = literalData.getDataLengthIfAvailable();
String originalFilename = literalData.getFileName();
@@ -571,7 +568,7 @@ public class PgpDecryptVerify extends BaseOperation {
literalData.getModificationTime().getTime(),
originalSize == null ? 0 : originalSize);
- if (!originalFilename.equals("")) {
+ if (!"".equals(originalFilename)) {
log.add(LogType.MSG_DC_CLEAR_META_FILE, indent + 1, originalFilename);
}
log.add(LogType.MSG_DC_CLEAR_META_MIME, indent + 1,
@@ -631,9 +628,8 @@ public class PgpDecryptVerify extends BaseOperation {
progress = 100;
}
progressScaler.setProgress((int) progress, 100);
- } else {
- // TODO: slow annealing to fake a progress?
}
+ // TODO: slow annealing to fake a progress?
}
if (signature != null) {
@@ -849,9 +845,8 @@ public class PgpDecryptVerify extends BaseOperation {
progress = 100;
}
progressScaler.setProgress((int) progress, 100);
- } else {
- // TODO: slow annealing to fake a progress?
}
+ // TODO: slow annealing to fake a progress?
}
updateProgress(R.string.progress_verifying_signature, 90, 100);