Displaying 1 result from an estimated 1 matches for "usb_get_interrupt".
2006 Nov 20
0
valgrind and libusb calls
...d I'd "clean my own house" first.
The problem is that the buffers returned from libusb are all being
marked as invalid (the bytes themselves, not the address).
I see at least two solutions to this:
1) Clear all buffers to zero before calling libusb functions that
write to a buffer (usb_get_interrupt, usb_get_string*,
usb_control_msg, etc.)
2) Mark the valid portions of the buffer after the libusb call with
VALGRIND_MAKE_READABLE.
The big advantage of the first method is that it keeps the code
looking clean, and means we don't have to do any conditional inclusion
of valgrind's memchec...