mirror of
https://github.com/shadps4-emu/ext-libusb.git
synced 2026-01-31 00:55:21 +01:00
467b6a8896daea3d104958bf0887312c5d14d150
Fix recent regression introduced in commit 9d595d4.
get_dev_port_number() was always returning port number 0 for any port,
due to the incorrect assumption that strtoll's 'end' pointer will point
to a null terminator on success. This was causing
winusb_get_device_list() to always fail. Since we actually know the
expected values of *end for both the SPDRP_LOCATION_INFORMATION and the
SPDRP_LOCATION_PATHS case, check for those instead.
Additionally, document why a return value of 0 is treated as a failure
in this particular function, for valid but somewhat coincidental reasons
that may not be immediately obvious.
Closes #1544
libusb
libusb is a library for USB device access from Linux, macOS, Windows, OpenBSD/NetBSD, Haiku, Solaris userspace, and WebAssembly via WebUSB. 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: https://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
- Hans de Goede hdegoede@redhat.com
- Xiaofan Chen xiaofanc@gmail.com
- Ludovic Rousseau ludovic.rousseau@gmail.com
- Nathan Hjelm hjelmn@cs.unm.edu
- Chris Dickens christopher.a.dickens@gmail.com
(Please use the mailing list rather than mailing developers directly)
Description
⚠️ ARCHIVED: Original GitHub repository no longer exists. Preserved as backup on 2026-01-31T05:30:30.373Z
Languages
C
91.5%
C++
4.8%
M4
1.3%
Makefile
1.1%
CMake
0.6%
Other
0.6%