mime: respect charset header (default to utf-8)

This commit is contained in:
Vincent Breitmoser committed 2015-09-16 19:54:57 +02:00
1 parent ece06b1933
commit 6624d1f830
7 files changed
+21 -25

No files matched your search

@@ -628,15 +628,14 @@ public class OpenPgpService extends RemoteService {
}
}
OpenPgpMetadata metadata = pgpResult.getDecryptionMetadata();
if (data.getIntExtra(OpenPgpApi.EXTRA_API_VERSION, -1) >= 4) {
OpenPgpMetadata metadata = pgpResult.getDecryptionMetadata();
if (metadata != null) {
result.putExtra(OpenPgpApi.RESULT_METADATA, metadata);
}
}
String charset = pgpResult.getCharset();
String charset = metadata != null ? metadata.getCharset() : null;
if (charset != null) {
result.putExtra(OpenPgpApi.RESULT_CHARSET, charset);
}