Bug 819937: fix multiple sms-delivery messages sent. r=yhuang

This commit is contained in:
Vicamo Yang 2013-01-11 00:49:12 +08:00
Родитель b66143e6bf
Коммит ed3782edfb
1 изменённых файлов: 6 добавлений и 12 удалений

Просмотреть файл

@ -3598,12 +3598,6 @@ let RIL = {
delete this._pendingSentSmsMap[message.messageRef];
if ((options.segmentMaxSeq > 1)
&& (options.segmentSeq < options.segmentMaxSeq)) {
// Not the last segment.
return PDU_FCS_OK;
}
let deliveryStatus = ((status >>> 5) == 0x00)
? GECKO_SMS_DELIVERY_STATUS_SUCCESS
: GECKO_SMS_DELIVERY_STATUS_ERROR;
@ -4409,17 +4403,17 @@ RIL[REQUEST_SEND_SMS] = function REQUEST_SEND_SMS(length, options) {
options.ackPDU = Buf.readString();
options.errorCode = Buf.readUint32();
if (options.requestStatusReport) {
if (DEBUG) debug("waiting SMS-STATUS-REPORT for messageRef " + options.messageRef);
this._pendingSentSmsMap[options.messageRef] = options;
}
if ((options.segmentMaxSeq > 1)
&& (options.segmentSeq < options.segmentMaxSeq)) {
// Not last segment
this._processSentSmsSegment(options);
} else {
// Last segment sent with success. Report it.
// Last segment sent with success.
if (options.requestStatusReport) {
if (DEBUG) debug("waiting SMS-STATUS-REPORT for messageRef " + options.messageRef);
this._pendingSentSmsMap[options.messageRef] = options;
}
this.sendDOMMessage({
rilMessageType: "sms-sent",
envelopeId: options.envelopeId,