Pulse-Eight / cec-dotnet

.Net implementations using libCEC
Other
24 stars 10 forks source link

Fix null-reference exception when running cec-tray #12

Closed nickkossolapov closed 4 years ago

nickkossolapov commented 4 years ago

Remove disposing of registry key inside of using statement. RegistryKey implements IDisposible, so using will call close automatically when key goes out of scope.

This fix is in relation to https://github.com/Pulse-Eight/libcec/issues/522 .

Note: I'm not sure if this is related to this change, but when running cec-tray from Visual Studio, it appears as though the firmware update for my device is not working. In the screenshot below, my firmware is only at v8, yet on the support page http://support.pulse-eight.com/support/solutions/articles/30000041207 it seems the latest firmware for this device is at v12. Additionally, there is no disabled update button.

image

opdenkamp commented 4 years ago

thanks, looks like I've missed that one after changing it to using indeed. I'll include the fix in the next build.

as for the firmware version: it's looking for the upgrade executable which is downloaded by the installer in one of the parent dirs. it's not found when running the app in visual studio, which will hide the button. so this is expected.