model->analog_channels);
for (i = 0; i < model->analog_channels; i++) {
- if (!(channel_name = g_strdup_printf("CH%d", i + 1)))
- return NULL;
+ channel_name = g_strdup_printf("CH%d", i + 1);
ch = sr_channel_new(sdi, i, SR_CHANNEL_ANALOG, TRUE, channel_name);
devc->analog_groups[i] = g_malloc0(sizeof(struct sr_channel_group));
devc->digital_group = g_malloc0(sizeof(struct sr_channel_group));
for (i = 0; i < ARRAY_SIZE(devc->digital_channels); i++) {
- if (!(channel_name = g_strdup_printf("D%d", i)))
- return NULL;
+ channel_name = g_strdup_printf("D%d", i);
ch = sr_channel_new(sdi, i, SR_CHANNEL_LOGIC, TRUE, channel_name);
g_free(channel_name);
devc->digital_group->channels = g_slist_append(