}
if (!lines[l]) {
/* Not enough data for a proper line yet. */
- ret = SR_OK_CONTINUE;
+ ret = SR_ERR_NA;
goto out;
}
if (inc->header && inc->multi_column_mode && strlen(columns[i]))
g_string_assign(channel_name, columns[i]);
else
- g_string_printf(channel_name, "%lu", i);
+ g_string_printf(channel_name, "%zu", i);
ch = sr_channel_new(i, SR_CHANNEL_LOGIC, TRUE, channel_name->str);
in->sdi->channels = g_slist_append(in->sdi->channels, ch);
}
else
max_columns = 1;
+ ret = SR_OK;
lines = g_strsplit_set(in->buf->str, "\r\n", 0);
for (l = 0; lines[l]; l++) {
inc->line_number++;
return ret;
}
-static int cleanup(struct sr_input *in)
+static void cleanup(struct sr_input *in)
{
struct context *inc;
if (inc->sample_buffer)
g_free(inc->sample_buffer);
-
- return SR_OK;
}
static struct sr_option options[] = {