crash [@ java.lang.IndexOutOfBoundsException: charAt: 1 >= length 1: at android.text.SpannableStringBuilder.charAt(SpannableStringBuilder.java)]

VERIFIED FIXED in Firefox 13

Status

()

Firefox for Android
Keyboards and IME
--
critical
VERIFIED FIXED
5 years ago
5 years ago

People

(Reporter: nhirata, Assigned: cpeterson)

Tracking

({crash})

14 Branch
Firefox 14
ARM
Android
crash
Points:
---

Firefox Tracking Flags

(firefox13 verified, firefox14 verified, blocking-fennec1.0 +)

Details

(Whiteboard: [native-crash], crash signature)

Attachments

(1 attachment)

This bug was filed from the Socorro interface and is 
report bp-b38c6bd8-34fe-4c85-9362-db3c42120221 .
============================================================= 
java.lang.IndexOutOfBoundsException: charAt: 1 >= length 1
	at android.text.SpannableStringBuilder.charAt(SpannableStringBuilder.java:112)
	at org.mozilla.gecko.GeckoInputConnection.onTextChanged(GeckoInputConnection.java:459)
	at android.text.SpannableStringBuilder.sendTextChange(SpannableStringBuilder.java:889)
	at android.text.SpannableStringBuilder.change(SpannableStringBuilder.java:352)
	at android.text.SpannableStringBuilder.change(SpannableStringBuilder.java:269)
	at android.text.SpannableStringBuilder.replace(SpannableStringBuilder.java:432)
	at android.text.SpannableStringBuilder.replace(SpannableStringBuilder.java:409)
	at android.text.SpannableStringBuilder.replace(SpannableStringBuilder.java:28)
	at android.text.method.QwertyKeyListener.onKeyDown(QwertyKeyListener.java:222)
	at android.text.method.TextKeyListener.onKeyDown(TextKeyListener.java:132)
	at org.mozilla.gecko.GeckoInputConnection.processKeyDown(GeckoInputConnection.java:684)
	at org.mozilla.gecko.GeckoInputConnection.onKeyPreIme(GeckoInputConnection.java:638)
	at org.mozilla.gecko.gfx.LayerView.onKeyPreIme(LayerView.java:150)
	at android.view.View.dispatchKeyEventPreIme(View.java:3876)
	at android.view.ViewGroup.dispatchKeyEventPreIme(ViewGroup.java:794)
	at android.view.ViewGroup.dispatchKeyEventPreIme(ViewGroup.java:794)
	at android.view.ViewGroup.dispatchKeyEventPreIme(ViewGroup.java:794)
	at android.view.ViewGroup.dispatchKeyEventPreIme(ViewGroup.java:794)
	at android.view.ViewRoot.deliverKeyEvent(ViewRoot.java:2637)
	at android.view.ViewRoot.handleMessage(ViewRoot.java:1953)
	at android.os.Handler.dispatchMessage(Handler.java:99)
	at android.os.Looper.loop(Looper.java:143)
	at org.mozilla.gecko.GeckoApp$34.run(GeckoApp.java:1807)
	at android.os.Handler.handleCallback(Handler.java:587)
	at android.os.Handler.dispatchMessage(Handler.java:92)
	at android.os.Looper.loop(Looper.java:143)
	at android.app.ActivityThread.main(ActivityThread.java:4196)
	at java.lang.reflect.Method.invokeNative(Native Method)
	at java.lang.reflect.Method.invoke(Method.java:507)
	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:839)
	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:597)
	at dalvik.system.NativeStart.main(Native Method)

Only one crash so far : 
Build : 20120221031301
'HTC Vision'
(Assignee)

Updated

5 years ago
Assignee: nobody → cpeterson

Comment 1

5 years ago
nom'ing for triage.
blocking-fennec1.0: --- → ?
blocking-fennec1.0: ? → +
(Assignee)

Updated

5 years ago
Assignee: cpeterson → nobody
Component: General → IME
QA Contact: general → ime
(Assignee)

Updated

5 years ago
Assignee: nobody → cpeterson
(Assignee)

Comment 2

5 years ago
Created attachment 605235 [details] [diff] [review]
bug-731034-clamp-keydown-selection.patch

Clamp current selection before processing key down events to avoid IndexOutOfBoundsException.
Attachment #605235 - Flags: review?(blassey.bugs)
(Assignee)

Updated

5 years ago
Blocks: 726393
Status: NEW → ASSIGNED
(Assignee)

Updated

5 years ago
No longer blocks: 726393
Depends on: 726393
Attachment #605235 - Flags: review?(blassey.bugs) → review+
(Assignee)

Updated

5 years ago
Keywords: checkin-needed
(Assignee)

Comment 3

5 years ago
Waiting for bug 726393 to land before checkin-needed.
Keywords: checkin-needed
(Assignee)

Comment 4

5 years ago
Bug 726393 landed, so this bug is now ready for checkin-needed.
Keywords: checkin-needed
https://hg.mozilla.org/integration/mozilla-inbound/rev/6106fe49a28d
Flags: in-testsuite?
Keywords: checkin-needed
Version: Firefox 13 → Firefox 14
https://hg.mozilla.org/mozilla-central/rev/6106fe49a28d
Status: ASSIGNED → RESOLVED
Last Resolved: 5 years ago
Resolution: --- → FIXED
Target Milestone: --- → Firefox 14
(Assignee)

Comment 7

5 years ago
Comment on attachment 605235 [details] [diff] [review]
bug-731034-clamp-keydown-selection.patch

[Approval Request Comment]
Regression caused by (bug #): N/A
User impact if declined: Keyboard crash
Testing completed (on m-c, etc.): m-c
Risk to taking this patch (and alternatives if risky): Android Java only.
String changes made by this patch: N/A
Attachment #605235 - Flags: approval-mozilla-aurora?

Comment 8

5 years ago
Comment on attachment 605235 [details] [diff] [review]
bug-731034-clamp-keydown-selection.patch

[Triage Comment]
Mobile only - approved for Aurora 13.
Attachment #605235 - Flags: approval-mozilla-aurora? → approval-mozilla-aurora+
https://hg.mozilla.org/releases/mozilla-aurora/rev/1aed4f63bb78
status-firefox13: --- → fixed
status-firefox14: --- → fixed

Comment 10

5 years ago
I'm setting this as verified/fixed since it wasn't reported for the last 4 weeks.
Status: RESOLVED → VERIFIED
status-firefox13: fixed → verified
status-firefox14: fixed → verified
Flags: in-testsuite?
You need to log in before you can comment on or make changes to this bug.