Bug 890218 - [MMS] If reboot device while downloading MMS attachment, the message will be empty and will not be deleted anymore. r=gene

This commit is contained in:
Chia-hung Tai 2013-07-11 10:03:47 +08:00
parent 7dfe369ada
commit 48fa8fb422

View File

@ -780,6 +780,11 @@ MobileMessageDatabaseService.prototype = {
if (DEBUG) {
debug("MMS: part[" + i + "]: " + JSON.stringify(part));
}
// Sometimes the part is incomplete because the device reboots when
// downloading MMS. Don't need to expose this part to the content.
if (!part) {
continue;
}
let partHeaders = part["headers"];
let partContent = part["content"];