]> sigrok.org Git - libsigrok.git/blobdiff - src/hardware/hantek-6xxx/api.c
sr_config_set(): Factor out SR_ERR_DEV_CLOSED check.
[libsigrok.git] / src / hardware / hantek-6xxx / api.c
index 025695e1df41cf1b913664be95e5e38e85752545..a17ec668987d6537cd307e4078df0fe20e277973 100644 (file)
@@ -401,9 +401,6 @@ static int config_set(uint32_t key, GVariant *data, const struct sr_dev_inst *sd
        unsigned int i;
        const char *tmp_str;
 
-       if (sdi->status != SR_ST_ACTIVE)
-               return SR_ERR_DEV_CLOSED;
-
        ret = SR_OK;
        devc = sdi->priv;
        if (!cg) {
@@ -784,9 +781,6 @@ static int dev_acquisition_start(const struct sr_dev_inst *sdi)
        struct sr_dev_driver *di = sdi->driver;
        struct drv_context *drvc = di->context;
 
-       if (sdi->status != SR_ST_ACTIVE)
-               return SR_ERR_DEV_CLOSED;
-
        devc = sdi->priv;
 
        if (configure_channels(sdi) != SR_OK) {