-
Notifications
You must be signed in to change notification settings - Fork 904
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
Mac: hid_exit() crasher on bad access 0 #92
Comments
Which version? Using latest from git repo? Can you isolate which version this problem started in? |
Encountering this same issue with the latest version. Was it solved? |
This is not the repo of the latest version. |
I understand that this is not the latest. I am using the latest as you linked above. However, I MAY have stumbled upon a "fix", add a 200ms delay between IOHIDManagerClose and CFRelease in the hid_exit method seems to work for me. |
In the hid_exit for mac/hid.c (libusb/hidapi), we call IOHIDManagerClose, but there isn't a corresponding IOHIDManagerOpen anywhere in the code except in main() |
Program received signal EXC_BAD_ACCESS, Could not access memory.
Reason: 13 at address: 0x0000000000000000
[Switching to process 61712 thread 0x1703]
0x00007fff89770697 in CFSetGetValue ()
(gdb) bt
#0 0x00007fff89770697 in CFSetGetValue ()
#1 0x00007fff8977e5f0 in __CFRunLoopFindMode ()
#2 0x00007fff8978d0f5 in CFRunLoopRemoveSource ()
#3 0x00007fff8d1754f9 in IOHIDDeviceUnscheduleFromRunLoop ()
#4 0x00007fff8d1771bc in __IOHIDManagerDeviceApplier ()
#5 0x00007fff897582d2 in __CFSetApplyFunction_block_invoke_1 ()
#6 0x00007fff89758121 in CFBasicHashApply ()
#7 0x00007fff897580a4 in CFSetApplyFunction ()
#8 0x00007fff8d17739f in IOHIDManagerUnscheduleFromRunLoop ()
#9 0x00007fff8d17740d in IOHIDManagerClose ()
#10 0x000000010002e49b in hid_exit () at hid.c:393
hid_close is called prior to hid_exit. Completely reproducible.
The text was updated successfully, but these errors were encountered: