summary | shortlog | log | commit | commitdiff | tree
raw | patch | inline | side by side (parent: e22c993)
raw | patch | inline | side by side (parent: e22c993)
author | Florian Forster <octo@leeloo.lan.home.verplant.org> | |
Tue, 8 May 2007 20:44:51 +0000 (22:44 +0200) | ||
committer | Florian Forster <octo@leeloo.lan.home.verplant.org> | |
Tue, 8 May 2007 20:44:51 +0000 (22:44 +0200) |
src/types_list.c | patch | blob | history |
diff --git a/src/types_list.c b/src/types_list.c
index 3963897e02e1c923e0642eb94b69efee4cfae8b0..002761ce3e7a76568df04612058d1492825595d2 100644 (file)
--- a/src/types_list.c
+++ b/src/types_list.c
if ((buf_len == 0) || (buf[0] == '#'))
continue;
+ while ((buf_len > 0) && ((buf[buf_len - 1] == '\n')
+ || (buf[buf_len - 1] == '\n')))
+ buf[--buf_len] = '\0';
+
+ if (buf_len == 0)
+ continue;
+
parse_line (buf, buf_len);
} /* while (fgets) */
} /* void parse_file */