mirror of
git://projects.qi-hardware.com/eda-tools.git
synced 2024-11-05 00:00:37 +02:00
genex/comp.c (read_desc): component missing in tree yields a warning, not error
We basically treat descriptions now more like libraries: they're allowed to contain more things than what we list in the tree.
This commit is contained in:
parent
54ecc10cbb
commit
1d47668b98
@ -143,7 +143,7 @@ void read_desc(FILE *file)
|
|||||||
char buf[1100]; /* more than enough */
|
char buf[1100]; /* more than enough */
|
||||||
struct node *node;
|
struct node *node;
|
||||||
char *p, *end;
|
char *p, *end;
|
||||||
int lineno = 0;
|
int skip = 0, lineno = 0;
|
||||||
|
|
||||||
while (fgets(buf, sizeof(buf), file)) {
|
while (fgets(buf, sizeof(buf), file)) {
|
||||||
lineno++;
|
lineno++;
|
||||||
@ -170,11 +170,15 @@ void read_desc(FILE *file)
|
|||||||
fprintf(stderr,
|
fprintf(stderr,
|
||||||
"component \"%s\" not found in line %d\n",
|
"component \"%s\" not found in line %d\n",
|
||||||
buf, lineno);
|
buf, lineno);
|
||||||
exit(1);
|
skip = 1;
|
||||||
|
continue;
|
||||||
}
|
}
|
||||||
for (anchor = &node->comment; *anchor;
|
for (anchor = &node->comment; *anchor;
|
||||||
anchor = &(*anchor)->next);
|
anchor = &(*anchor)->next);
|
||||||
|
skip = 0;
|
||||||
}
|
}
|
||||||
|
if (skip)
|
||||||
|
continue;
|
||||||
|
|
||||||
/* remove leading whitespace */
|
/* remove leading whitespace */
|
||||||
while (*p && isspace(*p))
|
while (*p && isspace(*p))
|
||||||
|
Loading…
Reference in New Issue
Block a user