]> sigrok.org Git - libsigrok.git/blobdiff - src/hardware/gwinstek-gds-800/api.c
sr_dev_open(): Set status to SR_ST_ACTIVE upon success.
[libsigrok.git] / src / hardware / gwinstek-gds-800 / api.c
index d64d43eb43dd3a73f10ce9efbef66744aae87d59..30407c3f4c61fa18b7c651cf68c4149a20589005 100644 (file)
@@ -98,8 +98,6 @@ static int dev_open(struct sr_dev_inst *sdi)
                return SR_ERR;
        }
 
-       sdi->status = SR_ST_ACTIVE;
-
        return SR_OK;
 }
 
@@ -107,9 +105,6 @@ static int dev_close(struct sr_dev_inst *sdi)
 {
        struct sr_scpi_dev_inst *scpi;
 
-       if (sdi->status != SR_ST_ACTIVE)
-               return SR_ERR_DEV_CLOSED;
-
        scpi = sdi->conn;
        if (scpi) {
                if (sr_scpi_close(scpi) < 0)