aboutsummaryrefslogtreecommitdiffstats
path: root/src/main/java/de/pixart/messenger
diff options
context:
space:
mode:
authorChristian Schneppe <christian@pix-art.de>2017-06-01 20:35:13 +0200
committerChristian Schneppe <christian@pix-art.de>2017-06-01 20:35:13 +0200
commit8ef4e7eed08393eafe6b2fe8fc794d1041d7ec57 (patch)
tree1d1e51c6decc9dadca9516a321cbac9c845c7a6f /src/main/java/de/pixart/messenger
parent796fad377b6423bedd94b996fc73b80762eb9610 (diff)
use application/pgp-encrypted mime type when necessary for http upload
Diffstat (limited to 'src/main/java/de/pixart/messenger')
-rw-r--r--src/main/java/de/pixart/messenger/http/HttpUploadConnection.java6
1 files changed, 5 insertions, 1 deletions
diff --git a/src/main/java/de/pixart/messenger/http/HttpUploadConnection.java b/src/main/java/de/pixart/messenger/http/HttpUploadConnection.java
index 84478561b..1488b3366 100644
--- a/src/main/java/de/pixart/messenger/http/HttpUploadConnection.java
+++ b/src/main/java/de/pixart/messenger/http/HttpUploadConnection.java
@@ -96,7 +96,11 @@ public class HttpUploadConnection implements Transferable {
this.message = message;
this.account = message.getConversation().getAccount();
this.file = mXmppConnectionService.getFileBackend().getFile(message, false);
- this.mime = this.file.getMimeType();
+ if (message.getEncryption() == Message.ENCRYPTION_PGP || message.getEncryption() == Message.ENCRYPTION_DECRYPTED) {
+ this.mime = "application/pgp-encrypted";
+ } else {
+ this.mime = this.file.getMimeType();
+ }
this.delayed = delay;
if (Config.ENCRYPT_ON_HTTP_UPLOADED
|| message.getEncryption() == Message.ENCRYPTION_AXOLOTL