/*
- * This file is part of the sigrok project.
+ * This file is part of the libsigrok project.
*
* Copyright (C) 2011 Daniel Ribeiro <drwyrm@gmail.com>
* Copyright (C) 2012 Renato Caldas <rmsc@fe.up.pt>
devc = sdi->priv;
if (sdi->status != SR_ST_ACTIVE)
- return SR_ERR;
+ return SR_ERR_DEV_CLOSED;
switch (id) {
case SR_CONF_SAMPLERATE:
struct dev_context *devc;
int ret = SR_ERR;
- devc = sdi->priv;
-
if (sdi->status != SR_ST_ACTIVE)
- return SR_ERR;
+ return SR_ERR_DEV_CLOSED;
+
+ devc = sdi->priv;
if (mso_configure_probes(sdi) != SR_OK) {
sr_err("Failed to configure probes.");