mirror of https://github.com/KLayout/klayout.git
Bugfix: entering '16:17' (or similar) into 'new layout' layer list made KLayout hang
This commit is contained in:
parent
abe9479ced
commit
b21f253cf8
|
|
@ -190,7 +190,7 @@ static bool read_ld (tl::Extractor &ex, ld_type &l, bool with_relative)
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
void
|
bool
|
||||||
LayerProperties::read (tl::Extractor &ex, bool as_target)
|
LayerProperties::read (tl::Extractor &ex, bool as_target)
|
||||||
{
|
{
|
||||||
layer = db::any_ld ();
|
layer = db::any_ld ();
|
||||||
|
|
@ -207,6 +207,8 @@ LayerProperties::read (tl::Extractor &ex, bool as_target)
|
||||||
layer = l;
|
layer = l;
|
||||||
datatype = d;
|
datatype = d;
|
||||||
|
|
||||||
|
return true;
|
||||||
|
|
||||||
} else if (ex.try_read_word_or_quoted (name)) {
|
} else if (ex.try_read_word_or_quoted (name)) {
|
||||||
|
|
||||||
if (ex.test ("(")) {
|
if (ex.test ("(")) {
|
||||||
|
|
@ -223,6 +225,10 @@ LayerProperties::read (tl::Extractor &ex, bool as_target)
|
||||||
|
|
||||||
}
|
}
|
||||||
|
|
||||||
|
return true;
|
||||||
|
|
||||||
|
} else {
|
||||||
|
return false;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
|
|
|
||||||
|
|
@ -91,8 +91,10 @@ struct DB_PUBLIC LayerProperties
|
||||||
* relative layer/datatype specifications in the format "*+1" or "*-100".
|
* relative layer/datatype specifications in the format "*+1" or "*-100".
|
||||||
* "*" for layer or datatype is for "don't care" (on input) or "leave as is"
|
* "*" for layer or datatype is for "don't care" (on input) or "leave as is"
|
||||||
* (for output).
|
* (for output).
|
||||||
|
*
|
||||||
|
* Returns true, if a layer was read successfully.
|
||||||
*/
|
*/
|
||||||
void read (tl::Extractor &ex, bool as_target = false);
|
bool read (tl::Extractor &ex, bool as_target = false);
|
||||||
|
|
||||||
/**
|
/**
|
||||||
* @brief "Logical" equality
|
* @brief "Logical" equality
|
||||||
|
|
|
||||||
|
|
@ -196,7 +196,9 @@ NewLayoutPropertiesDialog::exec_dialog (std::string &technology, std::string &ce
|
||||||
while (! ex.at_end ()) {
|
while (! ex.at_end ()) {
|
||||||
db::LayerProperties lp;
|
db::LayerProperties lp;
|
||||||
try {
|
try {
|
||||||
lp.read (ex);
|
if (! lp.read (ex)) {
|
||||||
|
break;
|
||||||
|
}
|
||||||
} catch (...) {
|
} catch (...) {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue