Prevent crash

This commit is contained in:
M66B 2019-01-23 07:19:32 +00:00
parent af89e052fd
commit fad6280bd6
1 changed files with 1 additions and 1 deletions

View File

@ -1288,7 +1288,7 @@ public class FragmentCompose extends FragmentBase {
os.write(buffer, 0, len);
// Update progress
if (attachment.size != null)
if (attachment.size != null && attachment.size > 0)
db.attachment().setProgress(attachment.id, (int) (size * 100 / attachment.size));
}