forked from Mirrors/openclonk
GetResStr: Match lines nongreedily (#993)
With greedy matching enabled, . (dot) would also match newlines.stable-5.4
parent
0757a0b834
commit
f0550c45b4
|
@ -405,7 +405,7 @@ namespace
|
|||
{
|
||||
std::string GetResStr(const char *id, const char *stringtbl)
|
||||
{
|
||||
static re::regex line_pattern("^([^=]+)=(.*)\\r?$", re::regex_constants::optimize);
|
||||
static re::regex line_pattern("^([^=]+)=(.*?)\r?$", static_cast<re::regex::flag_type>(re::regex_constants::optimize | re::regex_constants::ECMAScript));
|
||||
assert(stringtbl);
|
||||
if (!stringtbl)
|
||||
{
|
||||
|
|
Loading…
Reference in New Issue