I get casting errors when passing a struct by reference. Passing a pointer to a buffer works fine. The function getstuff() is actually libusb_claim_interface() with irrelevant parts removed. I am trying to get a chunk of data back from a USB device plugged into a Linux machine. The data comes in according to this struct: However, the code I was
Tag: libusb-1.0
libusb-1.0 hotplug events stop working in parent after fork(), when child calls libusb_exit()
I’ve been developing an application that monitors the USB device tree using libusb_hotplug_register_callback(). When a device that matches some criteria is attached, it will fork() and exec() an application to handle this device. The application has been working fine for some time now, but I’ve come back to try and ‘tidy it up’… libusb will open a number of file