X-Git-Url: http://sigrok.org/gitweb/?a=blobdiff_plain;f=src%2Fhardware%2Fhameg-hmo%2Fapi.c;h=7a2d91c7cc631d7c1d4997148d4de3782a9d5140;hb=6ec6c43b4738dbc7091f4a49a4ec80ea6102cb52;hp=4622ab613fd69b13f88cbbe278c6c1881c05a985;hpb=329733d92c5004f0fe308eff26b9537fded2cdf3;p=libsigrok.git diff --git a/src/hardware/hameg-hmo/api.c b/src/hardware/hameg-hmo/api.c index 4622ab61..7a2d91c7 100644 --- a/src/hardware/hameg-hmo/api.c +++ b/src/hardware/hameg-hmo/api.c @@ -17,7 +17,9 @@ * along with this program. If not, see . */ +#include #include +#include "scpi.h" #include "protocol.h" #define SERIALCOMM "115200/8n1/flow=1" @@ -109,20 +111,19 @@ fail: sr_scpi_hw_info_free(hw_info); if (sdi) sr_dev_inst_free(sdi); - if (devc) - g_free(devc); + g_free(devc); return NULL; } static GSList *scan(struct sr_dev_driver *di, GSList *options) { - return sr_scpi_scan(di->priv, options, hmo_probe_serial_device); + return sr_scpi_scan(di->context, options, hmo_probe_serial_device); } static GSList *dev_list(const struct sr_dev_driver *di) { - return ((struct drv_context *)(di->priv))->instances; + return ((struct drv_context *)(di->context))->instances; } static void clear_helper(void *priv) @@ -810,5 +811,5 @@ SR_PRIV struct sr_dev_driver hameg_hmo_driver_info = { .dev_close = dev_close, .dev_acquisition_start = dev_acquisition_start, .dev_acquisition_stop = dev_acquisition_stop, - .priv = NULL, + .context = NULL, };