Skip over lines that start with # (comments)
MFC after: 3 days
This commit is contained in:
parent
84da2236a4
commit
059d81a6e4
Notes:
svn2git
2020-12-20 02:59:44 +00:00
svn path=/head/; revision=291359
@ -87,6 +87,8 @@ load(const char *fname)
|
||||
if ((fp = fopen(fname, "r")) == NULL)
|
||||
err(1, "Cannot open `%s'", fname);
|
||||
while ((line = fgetln(fp, &len)) != NULL) {
|
||||
if (line[0] == '#')
|
||||
continue;
|
||||
char c = line[len];
|
||||
char *ptr;
|
||||
line[len] = '\0';
|
||||
|
Loading…
Reference in New Issue
Block a user