The beaglelogic has an open-coded version of std_dev_clear(), replace it with std_dev_clear().
Signed-off-by: Lars-Peter Clausen <[email protected]> --- src/hardware/beaglelogic/api.c | 20 +------------------- 1 file changed, 1 insertion(+), 19 deletions(-) diff --git a/src/hardware/beaglelogic/api.c b/src/hardware/beaglelogic/api.c index b974010..4951aff 100644 --- a/src/hardware/beaglelogic/api.c +++ b/src/hardware/beaglelogic/api.c @@ -202,25 +202,7 @@ static int dev_close(struct sr_dev_inst *sdi) static int cleanup(const struct sr_dev_driver *di) { - struct drv_context *drvc; - struct sr_dev_inst *sdi; - GSList *l; - - /* unused driver */ - if (!(drvc = di->context)) - return SR_OK; - - /* Clean up the instances */ - for (l = drvc->instances; l; l = l->next) { - sdi = l->data; - di->dev_close(sdi); - g_free(sdi->priv); - sr_dev_inst_free(sdi); - } - g_slist_free(drvc->instances); - drvc->instances = NULL; - - return SR_OK; + return std_dev_clear(di, NULL); } static int config_get(uint32_t key, GVariant **data, const struct sr_dev_inst *sdi, -- 2.1.4 ------------------------------------------------------------------------------ Find and fix application performance issues faster with Applications Manager Applications Manager provides deep performance insights into multiple tiers of your business applications. It resolves application problems quickly and reduces your MTTR. Get your free trial! https://ad.doubleclick.net/ddm/clk/302982198;130105516;z _______________________________________________ sigrok-devel mailing list [email protected] https://lists.sourceforge.net/lists/listinfo/sigrok-devel

