mirror of
https://git.code.sf.net/p/ngspice/ngspice
synced 2026-08-22 05:47:42 +02:00
Function ngSpice_Circ() may receive empty lines.
Skip these lines while setting the netlist.
This commit is contained in:
+5
-1
@@ -1878,8 +1878,12 @@ void create_circbyline(char *line, bool reset, bool lastline)
|
||||
circarray = TREALLOC(char *, circarray, n_elem_alloc);
|
||||
}
|
||||
|
||||
/* Remove any leading whitespace by shifting */
|
||||
char *p_src = skip_ws(line);
|
||||
/* An empty line may have been received. Skip it. */
|
||||
if (*p_src == '\0') {
|
||||
return;
|
||||
}
|
||||
/* Remove any leading whitespace by shifting */
|
||||
if (p_src != line) {
|
||||
char *p_dst = line;
|
||||
char ch_cur;
|
||||
|
||||
Reference in New Issue
Block a user