mirror of https://github.com/YosysHQ/yosys.git
Add check for BLIF with no model name
This commit is contained in:
parent
3046a06490
commit
b604c97b33
|
@ -166,7 +166,10 @@ void parse_blif(RTLIL::Design *design, std::istream &f, IdString dff_name, bool
|
||||||
goto error;
|
goto error;
|
||||||
module = new RTLIL::Module;
|
module = new RTLIL::Module;
|
||||||
lastcell = nullptr;
|
lastcell = nullptr;
|
||||||
module->name = RTLIL::escape_id(strtok(NULL, " \t\r\n"));
|
char *name = strtok(NULL, " \t\r\n");
|
||||||
|
if (name == nullptr)
|
||||||
|
goto error;
|
||||||
|
module->name = RTLIL::escape_id(name);
|
||||||
obj_attributes = &module->attributes;
|
obj_attributes = &module->attributes;
|
||||||
obj_parameters = nullptr;
|
obj_parameters = nullptr;
|
||||||
if (design->module(module->name))
|
if (design->module(module->name))
|
||||||
|
|
Loading…
Reference in New Issue