Without this change a segfault occurs at exit after scan, because
dev_close() is called and the device is believed to be open.
}
sdi = g_malloc0(sizeof(struct sr_dev_inst));
- sdi->status = SR_ST_ACTIVE;
+ sdi->status = SR_ST_INACTIVE;
sdi->vendor = g_strdup(vendor);
sdi->model = g_strdup(hw_info->model);
sdi->version = g_strdup(hw_info->firmware_version);
struct sr_scpi_dev_inst *scpi;
GVariant *beeper;
- if (sdi->status != SR_ST_ACTIVE)
+ if (sdi->status != SR_ST_INACTIVE)
return SR_ERR;
scpi = sdi->conn;