Browse Source

Leading space bug corrected.

pre-master-46
pnenzi 22 years ago
parent
commit
d0c3eaf5fe
  1. 7
      ChangeLog
  2. 2
      src/frontend/inpcom.c

7
ChangeLog

@ -1,3 +1,10 @@
2004-02-10 Paolo Nenzi <p.nenzi@ieee.org>
* src/frontend/inpcom.c: Applied patch from Dietmar Warning
to solve the bug discovered by Jelle Haandrikman: wrong
subcircuit expansion when leading spaces are present in the
subcircuit netlist.
2004-01-28 Paolo Nenzi <p.nenzi@ieee.org>
* configure.in: changed version to rework15.

2
src/frontend/inpcom.c

@ -56,7 +56,7 @@ readline(FILE *fd)
strptr = tmalloc(memlen);
memlen -= 1; /* Save constant -1's in while loop */
while((c = getc(fd)) != EOF) {
if (strlen == 0 && c == '\n')
if (strlen == 0 && (c == '\n' || c == ' ')) /* Leading spaces away */
continue;
strptr[strlen] = c;
strlen++;

Loading…
Cancel
Save