X-Git-Url: http://sigrok.org/gitweb/?a=blobdiff_plain;f=src%2Fhardware%2Fhameg-hmo%2Fapi.c;h=22fcbc54b3c07472689c18bd61a3c16ed86870d4;hb=3553451f1ed45d92bff11952cb131ac6a891b69f;hp=7e062b8d6f258feb05989dc9571ec67e5298a665;hpb=8bf18daabbf3cb0fec6c178b4bc7f6283a314e45;p=libsigrok.git diff --git a/src/hardware/hameg-hmo/api.c b/src/hardware/hameg-hmo/api.c index 7e062b8d..22fcbc54 100644 --- a/src/hardware/hameg-hmo/api.c +++ b/src/hardware/hameg-hmo/api.c @@ -110,21 +110,16 @@ static GSList *scan(struct sr_dev_driver *di, GSList *options) return sr_scpi_scan(di->context, options, hmo_probe_serial_device); } -static void clear_helper(void *priv) +static void clear_helper(struct dev_context *devc) { - struct dev_context *devc; - - devc = priv; - hmo_scope_state_free(devc->model_state); - g_free(devc->analog_groups); g_free(devc->digital_groups); } static int dev_clear(const struct sr_dev_driver *di) { - return std_dev_clear_with_callback(di, clear_helper); + return std_dev_clear_with_callback(di, (std_dev_clear_callback)clear_helper); } static int dev_open(struct sr_dev_inst *sdi)