XamarinCommunityToolkit
XamarinCommunityToolkit copied to clipboard
[Bug] CameraFragment.DisposeImageReader (): System.NullReferenceException: Object reference not set to an instance of an object
Description
One the tablets crashed today after taking a picture with the CameraView. With the following error:
CameraFragment.DisposeImageReader (): System.NullReferenceException: Object reference not set to an instance of an object
Stack Trace
System.NullReferenceException: Object reference not set to an instance of an object
at Xamarin.CommunityToolkit.UI.Views.CameraFragment.DisposeImageReader () [0x00013] in
I've checked the source CameraFragment.cs and the dispose is checked for null and is surrounded by Try {} Catch, but still it crashed the App
If there's anything i can add or log feel free to ask me.
Thanks in advance.
Link to Reproduction Sample
I'm sorry i can't reproduce it. Around 300 pictures were taken by 6 different devices. This was the only crash.
Steps to Reproduce
See above remark
Expected Behavior
Not to crash
Actual Behavior
Crashed
Basic Information
-
Version with issue: 1.2
-
Last known good version: -
-
IDE: VS 2019
-
Platform Target Frameworks:
- Android: Android 11
-
Android Support Library Version: /
-
Nuget Packages: /
-
Affected Devices: Samsung SM-T725
Workaround
None
Reproduction imagery
None report-2517680281170579999-2d5dc0c9-e3b0-440b-bb52-b79b22af0f56.txt
I got this issue as well in latest version. Hope it will be fixed soon.
There is a detailed analysis of this bug in https://github.com/xamarin/XamarinCommunityToolkit/issues/1413 The user even fixed the issue in his fork here: https://github.com/NuAoA/XamarinCommunityToolkit/commit/8f0d51df6a69bd48fa1640d2e04c5cf115140844 But unfortunately he doesn't made a pull request to the main repo.
Also getting this issue! A fixed version of the toolkit would help alot!
I am also facing this issue, hope it gets fixed in a newer version