rigol-ds: Don't run rigol_ds_block_wait() code unless supported.

This commit is contained in:
Martin Ling 2014-01-22 08:15:12 +00:00 committed by Bert Vermeulen
parent aff00e4088
commit 4472867a9f
1 changed files with 22 additions and 19 deletions

View File

@ -261,6 +261,8 @@ static int rigol_ds_block_wait(const struct sr_dev_inst *sdi)
if (!(devc = sdi->priv))
return SR_ERR;
if (devc->model->series->protocol >= PROTOCOL_V3) {
start = time(NULL);
do {
@ -284,6 +286,7 @@ static int rigol_ds_block_wait(const struct sr_dev_inst *sdi)
if (parse_int(buf + 5, &len) != SR_OK)
return SR_ERR;
} while (buf[0] == 'R' && len < 1000000);
}
rigol_ds_set_wait_event(devc, WAIT_NONE);