diff --git a/src/pickit5.c b/src/pickit5.c index 33f8b948..b951a4c6 100644 --- a/src/pickit5.c +++ b/src/pickit5.c @@ -661,7 +661,7 @@ static int pickit5_open(PROGRAMMER *pgm, const char *port) { int numids = str_set_vid_pid_serno(port, &new_vid, &new_pid, serno, sizeof serno); if(numids < 0) { pmsg_error("invalid -P %s; drop -P option or use -P usb[::][:]\n", port); - return LIBAVRDUDE_GENERAL_FAILURE; + return LIBAVRDUDE_EXIT_FAIL; } // If the config entry did not specify a USB PID, insert the default one diff --git a/src/usb_hidapi.c b/src/usb_hidapi.c index 7a6a790c..cb493a27 100644 --- a/src/usb_hidapi.c +++ b/src/usb_hidapi.c @@ -48,7 +48,7 @@ static int usbhid_open(const char *port, union pinfo pinfo, union filedescriptor // Override/set pid, vid and/or serno from -P usb[::][:] if(str_set_vid_pid_serno(port, &pinfo.usbinfo.vid, &pinfo.usbinfo.pid, serno, sizeof serno) < 0) { pmsg_error("invalid -P %s; drop -P option or use -P usb[::][:]\n", port); - return -1; + return LIBAVRDUDE_EXIT_FAIL; } if(*serno) { @@ -151,7 +151,7 @@ static int usbhid_open(const char *port, union pinfo pinfo, union filedescriptor // The JTAGICE3 running CMSIS-DAP doesn't use a separate endpoint for event reception fd->usb.eep = 0; fd->usb.max_xfer = 64; - pmsg_debug("usbhid_open(): product string: %s\n", cn); + pmsg_debug("%s(): product string: %s\n", __func__, cn); } } } diff --git a/src/usb_libusb.c b/src/usb_libusb.c index bdd14859..af576775 100644 --- a/src/usb_libusb.c +++ b/src/usb_libusb.c @@ -67,7 +67,7 @@ static int usbdev_open(const char *port, union pinfo pinfo, union filedescriptor // Override/set pid, vid and/or serno from -P usb[::][:] if(str_set_vid_pid_serno(port, &pinfo.usbinfo.vid, &pinfo.usbinfo.pid, serno, sizeof serno) < 0) { pmsg_error("invalid -P %s; drop -P option or use -P usb[::][:]\n", port); - return -1; + return LIBAVRDUDE_EXIT_FAIL; } usb_init();