X-Git-Url: http://sigrok.org/gitweb/?a=blobdiff_plain;f=src%2Fhardware%2Fbrymen-bm86x%2Fapi.c;h=c38665c1d8c678aa56da697447cec60fed525860;hb=0af636bed97c174bea46e61e961eaa1b0b162e0f;hp=f22535419fffdc8378c9bda879a2e0f290ada147;hpb=aed4ad0beaf64062752039a13f9a95326aa1df87;p=libsigrok.git diff --git a/src/hardware/brymen-bm86x/api.c b/src/hardware/brymen-bm86x/api.c index f2253541..c38665c1 100644 --- a/src/hardware/brymen-bm86x/api.c +++ b/src/hardware/brymen-bm86x/api.c @@ -73,11 +73,10 @@ static GSList *scan(GSList *options) for (l = usb_devices; l; l = l->next) { usb = l->data; - if (!(sdi = sr_dev_inst_new(SR_ST_INACTIVE, - "Brymen", "BM869", NULL))) { - sr_err("sr_dev_inst_new returned NULL."); - return NULL; - } + sdi = sr_dev_inst_new(); + sdi->status = SR_ST_INACTIVE; + sdi->vendor = g_strdup("Brymen"); + sdi->model = g_strdup("BM869"); if (!(devc = g_try_malloc0(sizeof(*devc)))) { sr_err("Device context malloc failed.");