Closed Bug 872219 Opened 12 years ago Closed 12 years ago

B2G MMS: "lastSegment is undefined" in RadioInterfaceLayer.js" L2544

Categories

(Core :: DOM: Device Interfaces, defect)

ARM
Gonk (Firefox OS)
defect
Not set
normal

Tracking

()

RESOLVED FIXED
mozilla24
Tracking Status
firefox22 --- wontfix
firefox23 --- fixed
firefox24 --- fixed
b2g18 --- fixed
b2g18-v1.0.0 --- wontfix
b2g18-v1.0.1 --- wontfix

People

(Reporter: rwaldron, Assigned: vicamo)

Details

(Whiteboard: [fixed-in-birch])

Attachments

(2 files, 1 obsolete file)

adb logcat reports this several times while running the SMS app: E/GeckoConsole( 578): [JavaScript Error: "lastSegment is undefined" {file: "jar:file:///system/b2g/omni.ja!/components/RadioInterfaceLayer.js" line: 2544}] https://hg.mozilla.org/releases/mozilla-b2g18/file/0e391e36361a/dom/system/gonk/RadioInterfaceLayer.js#l2544
Assignee: nobody → vyang
OS: Mac OS X → Gonk (Firefox OS)
Hardware: x86 → ARM
This API is supported to be called multiple times, and it seems we missed something when the input sting is empty. This shouldn't bring visible errors or anything that might have bad effects to user experience. Not nominating for leo+/tef+.
Attached patch Part 1/2: fixSplinter Review
Attachment #752681 - Flags: review?(gene.lian)
Comment on attachment 752681 [details] [diff] [review] Part 1/2: fix Review of attachment 752681 [details] [diff] [review]: ----------------------------------------------------------------- Good!
Attachment #752681 - Flags: review?(gene.lian) → review+
Comment on attachment 752683 [details] [diff] [review] Part 2/2: marionette test cases Review of attachment 752683 [details] [diff] [review]: ----------------------------------------------------------------- ::: dom/mobilemessage/tests/marionette/test_getsegmentinfofortext.js @@ +87,5 @@ > +// Testing empty object. The empty object extends to "[object Object]" and both > +// '[' and ']' are in default single shift table, so each of them takes two > +// septets. > +addTest({}, 1, PDU_MAX_USER_DATA_7BIT, > + PDU_MAX_USER_DATA_7BIT - (("" + {}).length + 2)); I tried to input "" + {} in my JS console. It shows: "[object Object]" why do you want to add 2? @@ +94,5 @@ > +let date = new Date(); > +addTest(date, 1, PDU_MAX_USER_DATA_7BIT, > + PDU_MAX_USER_DATA_7BIT - ("" + date).length); > + > +addTest("", 0, PDU_MAX_USER_DATA_7BIT, PDU_MAX_USER_DATA_7BIT); PDU_MAX_USER_DATA_7BIT - "".length looks more clear to me.
Attachment #752683 - Flags: review?(gene.lian)
Comment on attachment 752683 [details] [diff] [review] Part 2/2: marionette test cases Sorry, I misunderstood. :)
Attachment #752683 - Flags: review+
Address review comment. Also removes unused constants PDU_MAX_USER_DATA_8BIT and PDU_MAX_USER_DATA_UCS2.
Attachment #752683 - Attachment is obsolete: true
Attachment #753227 - Flags: review+
Status: NEW → RESOLVED
Closed: 12 years ago
Resolution: --- → FIXED
Target Milestone: --- → mozilla24
Comment on attachment 752681 [details] [diff] [review] Part 1/2: fix requesting approval because this clobbers our logs and make debugging more difficult. NOTE: Please see https://wiki.mozilla.org/Release_Management/B2G_Landing to better understand the B2G approval process and landings. [Approval Request Comment] Bug caused by (feature/regressing bug #): - User impact if declined: no real user impact afaik but this is called each time the user types a letter in a sms. AFAIK the error comes when we display an empty SMS. Testing completed: yes + marionette tests Risk to taking this patch (and alternatives if risky): low String or UUID changes made by this patch: none
Attachment #752681 - Flags: approval-mozilla-b2g18?
+1. That error message is really annoying. :(
Attachment #752681 - Flags: approval-mozilla-b2g18? → approval-mozilla-b2g18+
You need to log in before you can comment on or make changes to this bug.

Attachment

General

Created:
Updated:
Size: