Extra check message size

pull/194/merge
M66B 3 years ago
parent 1ee3ef6f5e
commit bcbe88d9be

@ -2007,8 +2007,9 @@ public class MessageHelper {
parts.addAll(text);
parts.addAll(extra);
for (PartHolder h : parts) {
if (h.part.getSize() > MAX_MESSAGE_SIZE) {
warnings.add(context.getString(R.string.title_insufficient_memory));
int size = h.part.getSize();
if (size > MAX_MESSAGE_SIZE && size != Integer.MAX_VALUE) {
warnings.add(context.getString(R.string.title_insufficient_memory, size));
return null;
}

@ -1125,7 +1125,7 @@
<string name="title_no_search">Search on server is not available for this account</string>
<string name="title_too_large">Message too large to completely reformat</string>
<string name="title_truncated">Message too large to display completely</string>
<string name="title_insufficient_memory">Message too large to fit into the available memory</string>
<string name="title_insufficient_memory">Message too large for the available memory (%1$d)</string>
<string name="title_show_full">Show full message</string>
<string name="title_unused_inline">Unused inline images will be removed on send</string>
<string name="title_accross_remark">Messages moved across accounts will be downloaded again resulting in extra data usage</string>

Loading…
Cancel
Save