]> sigrok.org Git - libsigrok.git/blobdiff - src/hardware/center-3xx/api.c
Eliminate sr_dev_inst_new().
[libsigrok.git] / src / hardware / center-3xx / api.c
index d5801ce907c65e3b8cd2cf59bbf8895cfeb556ba..13831c05a9af4b7b90e4771a31e2587e5bd78d61 100644 (file)
@@ -88,7 +88,7 @@ static GSList *center_scan(const char *conn, const char *serialcomm, int idx)
 
        sr_info("Found device on port %s.", conn);
 
-       sdi = sr_dev_inst_new();
+       sdi = g_malloc0(sizeof(struct sr_dev_inst));
        sdi->status = SR_ST_INACTIVE;
        sdi->vendor = g_strdup(center_devs[idx].vendor);
        sdi->model = g_strdup(center_devs[idx].device);