From 98e973eb17513dde540c57f67deef1ece079aa79 Mon Sep 17 00:00:00 2001 From: stefanrueger Date: Wed, 12 Aug 2026 20:25:47 +0200 Subject: [PATCH] Revert commit eb66125 Apparently the reasoning behing commit eb66125 was flawed for certain MSVC builds, see https://github.com/avrdudes/avrdude/issues/2175 --- src/usb_libusb.c | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/usb_libusb.c b/src/usb_libusb.c index 10b8f617..9e345bc9 100644 --- a/src/usb_libusb.c +++ b/src/usb_libusb.c @@ -145,6 +145,11 @@ static int usbdev_open(const char *port, union pinfo pinfo, union filedescriptor goto trynext; } + if(usb_set_configuration(udev, dev->config[0].bConfigurationValue)) { + pmsg_notice("(config value %d) %s\n", dev->config[0].bConfigurationValue, usb_strerror()); + // goto trynext; // Let's hope it has already been configured + } + int usehid = !!(pinfo.usbinfo.flags & PINFO_FL_USEHID); for(iface = 0; iface < dev->config[0].bNumInterfaces; iface++) { cx->usb_interface = dev->config[0].interface[iface].altsetting[0].bInterfaceNumber;