char *response;
#endif
- sdi = g_malloc0(sizeof(struct sr_dev_inst));
- sdi->conn = scpi;
-
#if ECHO_TEST
/* Test for serial port ECHO enabled. */
response = NULL;
}
/* Set up device parameters. */
+ sdi = g_malloc0(sizeof(struct sr_dev_inst));
sdi->vendor = g_strdup(model->vendor);
sdi->model = g_strdup(model->model);
sdi->version = g_strdup(hw_info->firmware_version);
sdi->conn = scpi;
sdi->driver = &fluke_45_driver_info;
sdi->inst_type = SR_INST_SCPI;
+ sr_scpi_hw_info_free(hw_info);
devc = g_malloc0(sizeof(struct dev_context));
devc->num_channels = model->num_channels;
devc->cmdset = cmdset;
+ sdi->priv = devc;
/* Create channels. */
for (i = 0; i < devc->num_channels; i++) {
sr_channel_new(sdi, 0, SR_CHANNEL_ANALOG, TRUE, channel_name);
}
- sdi->priv = devc;
-
return sdi;
}