Crash by a NullPointerException of QrFragment with Background Camera
Categories
(Fenix :: QR, defect)
Tracking
(firefox137 fixed)
Tracking | Status | |
---|---|---|
firefox137 | --- | fixed |
People
(Reporter: 1782769091, Assigned: royang)
References
Details
(Whiteboard: [fxdroid][group3])
Attachments
(1 file)
Steps to reproduce:
User Agent: Mozilla/5.0 (Android 10; Mobile; rv:137.0) Gecko/137.0 Firefox/137.0
I was in MoreOptions - Sync and save data.
Then I entered Ready to scan and went back, next Use email instead.
While I was configuring the email and some page settings, the background camera get a NullPointerException and cause the app crash.
Actual results:
FATAL EXCEPTION: CameraBackground
Process: org.mozilla.fenix.debug, PID: 21788
java.lang.NullPointerException: null cannot be cast to non-null type android.view.Surface
at mozilla.components.feature.qr.QrFragment$createCameraPreviewSession$1.invoke(QrFragment.kt:549)
at mozilla.components.feature.qr.QrFragment$createCameraPreviewSession$1.invoke(QrFragment.kt:546)
at mozilla.components.feature.qr.QrFragment.handleCaptureException(QrFragment.kt:623)
at mozilla.components.feature.qr.QrFragment.createCameraPreviewSession$feature_qr_debug(QrFragment.kt:546)
at mozilla.components.feature.qr.QrFragment$stateCallback$1.onOpened(QrFragment.kt:172)
at android.hardware.camera2.impl.CameraDeviceImpl$1.run(CameraDeviceImpl.java:143)
at android.os.Handler.handleCallback(Handler.java:873)
at android.os.Handler.dispatchMessage(Handler.java:99)
at android.os.Looper.loop(Looper.java:193)
at android.os.HandlerThread.run(HandlerThread.java:65)
Expected results:
The camera should be already exit porperly?
Comment 1•24 days ago
|
||
The severity field is not set for this bug.
:royang, could you have a look please?
For more information, please visit BugBot documentation.
Assignee | ||
Comment 2•24 days ago
|
||
Thanks for reporting this.
Can't reproduce but from the code it looks like this could happen and was not handled correctly. Add check and handle gracefully when surface is null.
Assignee | ||
Updated•24 days ago
|
Updated•24 days ago
|
Assignee | ||
Comment 3•24 days ago
|
||
Updated•24 days ago
|
Comment 5•20 days ago
|
||
bugherder |
Description
•