[Mac] Do not call CFRelease on HID properties

HID properties are callee-owned and should not be released by the
caller. Fixes crash (memory corruption) on device hot plugging.
This commit is contained in:
thefiddler 2014-01-05 21:27:34 +01:00
parent 02c9f471ea
commit 05af21e61b

View file

@ -408,7 +408,6 @@ namespace OpenTK.Platform.MacOS
CFStringRef name_ref = NativeMethods.IOHIDDeviceGetProperty(device, NativeMethods.IOHIDProductKey);
string name = CF.CFStringGetCString(name_ref);
CF.CFRelease(name_ref);
List<int> button_elements = new List<int>();
CFArray element_array = new CFArray(element_array_ref);