mirror of
https://github.com/amyinspace/MagicSetEditor2.git
synced 2026-06-12 13:37:00 -04:00
Fix: crash caused by keywords with empty parameter matches (partial fix for #33)
This commit is contained in:
@@ -580,7 +580,7 @@ bool KeywordDatabase::tryExpand(const Keyword& kw,
|
|||||||
if ((submatch % 2) == 0) {
|
if ((submatch % 2) == 0) {
|
||||||
// parameter
|
// parameter
|
||||||
KeywordParam& kwp = *kw.parameters[(submatch - 2) / 2];
|
KeywordParam& kwp = *kw.parameters[(submatch - 2) / 2];
|
||||||
String param = untagged.substr(part_start_u, part_len_u); // untagged version
|
String param = match.str((int)submatch); // untagged version
|
||||||
// strip separator_before
|
// strip separator_before
|
||||||
String separator_before, separator_after;
|
String separator_before, separator_after;
|
||||||
Regex::Results sep_match;
|
Regex::Results sep_match;
|
||||||
|
|||||||
Reference in New Issue
Block a user