summaryrefslogtreecommitdiff
path: root/src
diff options
context:
space:
mode:
Diffstat (limited to 'src')
-rw-r--r--src/transport/swd_libswd_drv_openocd.c3
1 files changed, 1 insertions, 2 deletions
diff --git a/src/transport/swd_libswd_drv_openocd.c b/src/transport/swd_libswd_drv_openocd.c
index 49a1f946..a357bad3 100644
--- a/src/transport/swd_libswd_drv_openocd.c
+++ b/src/transport/swd_libswd_drv_openocd.c
@@ -266,11 +266,10 @@ int swd_log(swd_ctx_t *swdctx, swd_loglevel_t loglevel, char *msg, ...){
if (loglevel > SWD_LOGLEVEL_MAX) return SWD_ERROR_PARAM;
if (loglevel > swdctx->config.loglevel) return SWD_OK;
- int res;
va_list ap;
va_start(ap, msg);
// Calling OpenOCD log functions here will cause program crash (va recurrent).
- res=vprintf(msg, ap);
+ vprintf(msg, ap);
va_end(ap);
return SWD_OK;
}