diff --git a/src/platforms/hosted/jlink_adiv5_swdp.c b/src/platforms/hosted/jlink_adiv5_swdp.c index 090c1f5..4332f60 100644 --- a/src/platforms/hosted/jlink_adiv5_swdp.c +++ b/src/platforms/hosted/jlink_adiv5_swdp.c @@ -186,8 +186,6 @@ int jlink_swdp_scan(bmp_info_t *info) jlink_adiv5_swdp_error(dp); adiv5_dp_init(dp); - if (!target_list) - free(dp); return target_list?1:0; } diff --git a/src/target/adiv5_swdp.c b/src/target/adiv5_swdp.c index 3369856..0678064 100644 --- a/src/target/adiv5_swdp.c +++ b/src/target/adiv5_swdp.c @@ -82,8 +82,6 @@ int adiv5_swdp_scan(void) firmware_swdp_error(dp); adiv5_dp_init(dp); - if (!target_list) - free(dp); return target_list?1:0; }