commit | e873677b9196b191d6cdbdf9783c6d6a18379249 | [log] [tgz] |
---|---|---|
author | Chris Dickens <christopher.a.dickens@gmail.com> | Fri Apr 17 13:22:34 2020 -0700 |
committer | Chris Dickens <christopher.a.dickens@gmail.com> | Fri Apr 17 13:22:34 2020 -0700 |
tree | f083f210da89a4647b76d881fc9ef6796c847ff7 | |
parent | 9ececdb0ecbbb77edd5a40cb8914ddc54b77dea2 [diff] |
descriptor: Minor improvements to the parse_descriptor() function Change the type of the source pointer to 'void' so that callers need not cast to 'unsigned char'. Also change working types to 'uint8_t' to make it explicit that we are dealing with 8-bit types. Refactor the parsing loop to avoid unnecessary stack variables. The generated assembly with this change is more efficient. Signed-off-by: Chris Dickens <christopher.a.dickens@gmail.com>
libusb is a library for USB device access from Linux, macOS, Windows, OpenBSD/NetBSD, Haiku and Solaris userspace. It is written in C (Haiku backend in C++) and licensed under the GNU Lesser General Public License version 2.1 or, at your option, any later version (see COPYING).
libusb is abstracted internally in such a way that it can hopefully be ported to other operating systems. Please see the PORTING file for more information.
libusb homepage: http://libusb.info/
Developers will wish to consult the API documentation: http://api.libusb.info
Use the mailing list for questions, comments, etc: http://mailing-list.libusb.info
(Please use the mailing list rather than mailing developers directly)