Skip to content

Commit

Permalink
drivers/libusb{0,1}.c: rename static nut_usb_set_altinterface() => nu…
Browse files Browse the repository at this point in the history
…t_libusb_set_altinterface() to maintain a consistent code style [networkupstools#2604]

Signed-off-by: Jim Klimov <[email protected]>
  • Loading branch information
jimklimov committed Sep 3, 2024
1 parent f06771d commit f1a3dbe
Show file tree
Hide file tree
Showing 2 changed files with 4 additions and 4 deletions.
4 changes: 2 additions & 2 deletions drivers/libusb0.c
Original file line number Diff line number Diff line change
Expand Up @@ -154,7 +154,7 @@ static inline int matches(USBDeviceMatcher_t *matcher, USBDevice_t *device) {
* devices from working on Mac OS X (presumably the OS is already setting
* altinterface to 0).
*/
static int nut_usb_set_altinterface(usb_dev_handle *udev)
static int nut_libusb_set_altinterface(usb_dev_handle *udev)
{
int altinterface = 0, ret = 0;
char *alt_string, *endp = NULL;
Expand Down Expand Up @@ -528,7 +528,7 @@ static int nut_libusb_open(usb_dev_handle **udevp,
#endif
/* if_claimed = 1; */

nut_usb_set_altinterface(udev);
nut_libusb_set_altinterface(udev);

/* Did the driver provide a callback method for any further
* device acceptance checks (e.g. when same ID is supported
Expand Down
4 changes: 2 additions & 2 deletions drivers/libusb1.c
Original file line number Diff line number Diff line change
Expand Up @@ -119,7 +119,7 @@ static inline int matches(USBDeviceMatcher_t *matcher, USBDevice_t *device) {
* devices from working on Mac OS X (presumably the OS is already setting
* altinterface to 0).
*/
static int nut_usb_set_altinterface(libusb_device_handle *udev)
static int nut_libusb_set_altinterface(libusb_device_handle *udev)
{
int altinterface = 0, ret = 0;
char *alt_string, *endp = NULL;
Expand Down Expand Up @@ -588,7 +588,7 @@ static int nut_libusb_open(libusb_device_handle **udevp,
upsdebugx(2, "Claimed interface %d successfully",
usb_subdriver.hid_rep_index);

nut_usb_set_altinterface(udev);
nut_libusb_set_altinterface(udev);

/* Did the driver provide a callback method for any further
* device acceptance checks (e.g. when same ID is supported
Expand Down

0 comments on commit f1a3dbe

Please sign in to comment.