mirror of https://gerrit.osmocom.org/libosmocore
msgfile: Allow to have comments in the simple CSV file
This commit is contained in:
parent
a1094c801f
commit
131bc80b96
|
@ -70,6 +70,10 @@ static void handle_line(struct msg_entries *entries, char *line)
|
||||||
char *items[3];
|
char *items[3];
|
||||||
int last_item = 0;
|
int last_item = 0;
|
||||||
|
|
||||||
|
/* Skip comments from the file */
|
||||||
|
if (line[0] == '#')
|
||||||
|
return;
|
||||||
|
|
||||||
for (i = 0; i < len; ++i) {
|
for (i = 0; i < len; ++i) {
|
||||||
if (line[i] == '\n' || line[i] == '\r')
|
if (line[i] == '\n' || line[i] == '\r')
|
||||||
line[i] = '\0';
|
line[i] = '\0';
|
||||||
|
|
|
@ -1 +1,2 @@
|
||||||
|
# This is a comment
|
||||||
*:*::Hello Welt
|
*:*::Hello Welt
|
||||||
|
|
Loading…
Reference in New Issue