From 09479138f00906ec5c77c3702e24bad676b7e9bf Mon Sep 17 00:00:00 2001 From: dreamsourcelabTAI Date: Fri, 22 Sep 2023 20:51:28 +0800 Subject: [PATCH] fix: The program enters a dead loop after click stop --- libsigrok4DSL/hardware/DSL/dsl.c | 8 ++------ 1 file changed, 2 insertions(+), 6 deletions(-) diff --git a/libsigrok4DSL/hardware/DSL/dsl.c b/libsigrok4DSL/hardware/DSL/dsl.c index 0b4be079..c283495f 100644 --- a/libsigrok4DSL/hardware/DSL/dsl.c +++ b/libsigrok4DSL/hardware/DSL/dsl.c @@ -2027,13 +2027,9 @@ SR_PRIV int dsl_dev_acquisition_stop(const struct sr_dev_inst *sdi, void *cb_dat sr_info("%s: Sent acquisition stop command!", __func__); /* check a real stop of FPGA status*/ + uint8_t hw_status = 1; - while (hw_status != 0) { - if (dsl_rd_reg(sdi, HW_STATUS_ADDR, &hw_status) != SR_OK) - sr_err("%s: Get hardware status command failed!", __func__); - else - sr_info("%s: Get hardware status command!", __func__); - } + dsl_rd_reg(sdi, HW_STATUS_ADDR, &hw_status); /* adc power down*/ if (devc->profile->dev_caps.feature_caps & CAPS_FEATURE_HMCAD1511) {