-
-
Notifications
You must be signed in to change notification settings - Fork 7
New issue
Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.
By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.
Already on GitHub? Sign in to your account
WMIHelper can't handle multiple result objects #114
Comments
Note this can also occur with dual-graphics laptops with e.g., an embedded Intel GPU and a discrete AMD or NVIDIA GPU. EDIT: Y'know, I think my wife has one of these. I'll test it when I get a chance. |
This fixes the crash mentioned in erri120#114 when multiple video controllers exist. Naively picking the first entry may not work for everyone, but it seems to be the right choice most of the time.
Sorry that "when I get a chance" turned out to be 3 months. The existing code does in fact crash on my wife's laptop, so I whipped up a quick PR that works for her. Based on some experiments with an EA integration for GOG Galaxy, picking the first entry yields the correct result for others that were in this boat. The OP's situation does seem a bit different, though. @UrbanCMC : Can you confirm that this PR doesn't work for you before we add a check for the Status field? |
Fixes erri120#114. Naively picking the first entry may not work for everyone, but it seems to be the right choice most of the time.
Fixes erri120#114. Naively picking the first entry may not work for everyone, but it seems to be the right choice most of the time.
With your PR the decryption key is created successfully. Looks like EA didn't consider this edge case either. |
This fixes the crash mentioned in erri120#114 when multiple video controllers exist. Naively picking the first entry may not work for everyone, but it seems to be the right choice most of the time.
This fixes the crash mentioned in erri120#114 when multiple video controllers exist. Naively picking the first entry may not work for everyone, but it seems to be the right choice most of the time.
Fixed by #132. |
In my case this happens when trying to get the display adpater for building the EA Desktop decryption key.
This is probably not too common, but I have WMI showing more than one display adapter (the second one being created by the VR software
Virtual Desktop
).This might actually be a good thing in this case, because the "wrong" display adapter is listed first, which as far as I can tell would have created an invalid decryption key.
For this specific scenario it should be possible to determine the correct display adapter by checking the
Status
of the devices returned by WMI, because Virtual Desktop keeps the adapter disabled unless it is actively used (VD's adapter shows a status ofError
, while the real one showsOK
).Stacktrace:
Full
Win32_VideoController
output, in case you want to look for a better way of getting the right one:The text was updated successfully, but these errors were encountered: