LibCecSharp: set the callback methods in libcec to NULL before closing the connection...
authorLars Op den Kamp <lars@opdenkamp.eu>
Tue, 14 Feb 2012 14:44:50 +0000 (15:44 +0100)
committerLars Op den Kamp <lars@opdenkamp.eu>
Tue, 14 Feb 2012 14:44:50 +0000 (15:44 +0100)
src/LibCecSharp/LibCecSharp.cpp

index c6f52a1a17b2bda673177728538602c81421b669..4e76ead7a6ab264252ef97040448e9909fb93729 100644 (file)
@@ -136,6 +136,8 @@ namespace CecSharp
 
                void Close(void)
                {
+                       // delete the callbacks, since these might already have been destroyed in .NET
+                       m_libCec->EnableCallbacks(NULL, NULL);
                        m_libCec->Close();
                }