If you think a bug might affect users in the 57 release, please set the correct tracking and status flags for Release Management.

NoSuchMethodError: java.lang.Math.copySign

VERIFIED FIXED

Status

()

Firefox for Android
General
--
blocker
VERIFIED FIXED
6 years ago
a year ago

People

(Reporter: kats, Assigned: kats)

Tracking

({crash})

Firefox Tracking Flags

(Not tracked)

Details

(Whiteboard: [native-crash])

Attachments

(1 attachment, 1 obsolete attachment)

I loaded www.google.com/webfonts on the Droid Pro using an m-c build from today (December 13), rotated, and tried to pan. Fennec crashed with the following in logcat:

12-13 16:58:34.650  2351  2351 E AndroidRuntime: FATAL EXCEPTION: main
12-13 16:58:34.650  2351  2351 E AndroidRuntime: java.lang.NoSuchMethodError: java.lang.Math.copySign
12-13 16:58:34.650  2351  2351 E AndroidRuntime: 	at org.mozilla.gecko.ui.PanZoomController$Axis.advanceFling(PanZoomController.java:779)
12-13 16:58:34.650  2351  2351 E AndroidRuntime: 	at org.mozilla.gecko.ui.PanZoomController$FlingRunnable.run(PanZoomController.java:627)
12-13 16:58:34.650  2351  2351 E AndroidRuntime: 	at android.os.Handler.handleCallback(Handler.java:587)
12-13 16:58:34.650  2351  2351 E AndroidRuntime: 	at android.os.Handler.dispatchMessage(Handler.java:92)
12-13 16:58:34.650  2351  2351 E AndroidRuntime: 	at android.os.Looper.loop(Looper.java:143)
12-13 16:58:34.650  2351  2351 E AndroidRuntime: 	at org.mozilla.gecko.GeckoApp$26.run(GeckoApp.java:1372)
12-13 16:58:34.650  2351  2351 E AndroidRuntime: 	at android.os.Handler.handleCallback(Handler.java:587)
12-13 16:58:34.650  2351  2351 E AndroidRuntime: 	at android.os.Handler.dispatchMessage(Handler.java:92)
12-13 16:58:34.650  2351  2351 E AndroidRuntime: 	at android.os.Looper.loop(Looper.java:143)
12-13 16:58:34.650  2351  2351 E AndroidRuntime: 	at android.app.ActivityThread.main(ActivityThread.java:4717)
12-13 16:58:34.650  2351  2351 E AndroidRuntime: 	at java.lang.reflect.Method.invokeNative(Native Method)
12-13 16:58:34.650  2351  2351 E AndroidRuntime: 	at java.lang.reflect.Method.invoke(Method.java:521)
12-13 16:58:34.650  2351  2351 E AndroidRuntime: 	at com.android.internal.os.ZygoteInit$MethodAndArgsCaller.run(ZygoteInit.java:860)
12-13 16:58:34.650  2351  2351 E AndroidRuntime: 	at com.android.internal.os.ZygoteInit.main(ZygoteInit.java:618)
12-13 16:58:34.650  2351  2351 E AndroidRuntime: 	at dalvik.system.NativeStart.main(Native Method)

Apparently the method was added in API version 9, and the Droid Pro is running Android 2.2 (API version 8), so it doesn't have that function.

Updated

6 years ago
Duplicate of this bug: 710758
Assignee: nobody → bugmail.mozilla
Created attachment 581697 [details] [diff] [review]
Stop using copysign
Attachment #581697 - Flags: review?(chrislord.net)
Duplicate of this bug: 710187

Updated

6 years ago
Severity: normal → blocker

Comment 4

6 years ago
Comment on attachment 581697 [details] [diff] [review]
Stop using copysign

Review of attachment 581697 [details] [diff] [review]:
-----------------------------------------------------------------

Looks good, thanks.
Attachment #581697 - Flags: review?(chrislord.net) → review+

Updated

6 years ago
Keywords: crash
Whiteboard: [native-crash]
Created attachment 581710 [details] [diff] [review]
Stop using copysign (v2)

Updated so we don't fall into this case for Math.pow:

 pow((-anything except 0 and inf), (non-integer)) = NAN

and end up with NaNs all over the place.
Attachment #581697 - Attachment is obsolete: true
Attachment #581710 - Flags: review?(chrislord.net)

Comment 6

6 years ago
Comment on attachment 581710 [details] [diff] [review]
Stop using copysign (v2)

Review of attachment 581710 [details] [diff] [review]:
-----------------------------------------------------------------

Yup, looks good.
Attachment #581710 - Flags: review?(chrislord.net) → review+
Landed on m-c since pcwalton seems to be gone and may or may not land his bug 710119 patch today, and this really needs to be fixed.

https://hg.mozilla.org/mozilla-central/rev/41f75cbb91f2
Status: NEW → RESOLVED
Last Resolved: 6 years ago
Resolution: --- → FIXED
Motorola Droid Pro (Android 2.3)
20111215075015
http://hg.mozilla.org/mozilla-central/rev/bbb2149b613e

Updated

6 years ago
Status: RESOLVED → VERIFIED
You need to log in before you can comment on or make changes to this bug.