-
Notifications
You must be signed in to change notification settings - Fork 40
Open
Description
Describe the bug
Some users intermittently experience a NullReferenceException when calling MediaDevice.GetDevices(). This exception does not occur for all users, and the cause is not entirely clear.
To Reproduce
1. Call `MediaDevice.GetDevices()` in a system with portable devices connected.
2. For certain users, a `NullReferenceException` is thrown.
Expected behavior
The method should return a valid list of MediaDevice objects or an empty list if no devices are available.
Device
Various devices and operating systems (details unknown).
Version:
1.10.0.0.
Additional context
It is possible that deviceManager is not properly initialized, or deviceIds may contain null values. Adding null checks for both deviceManager and deviceIds in the GetDevices() method could resolve this issue. I can prepare a PR for this case if you would like.
Reactions are currently unavailable
Metadata
Metadata
Assignees
Labels
No labels