pc-stlinkv2: Return failure if STLINK_DEBUG_APIV2_INIT_AP fails.

This commit is contained in:
Uwe Bonnes 2019-08-28 16:04:00 +02:00
parent d994565f2e
commit a01109543e
1 changed files with 1 additions and 2 deletions

View File

@ -1079,8 +1079,7 @@ bool adiv5_ap_setup(int ap)
uint8_t data[2];
send_recv_retry(cmd, 16, data, 2);
DEBUG_STLINK("Open AP %d\n", ap);
stlink_usb_error_check(data, true);
return true;
return (stlink_usb_error_check(data, true))? false: true;
}
void adiv5_ap_cleanup(int ap)