Skip to content

Commit

Permalink
Backport fix for #7369 - 4.0.2: build fails against re2 20220601.
Browse files Browse the repository at this point in the history
  • Loading branch information
asfernandes committed Oct 31, 2022
1 parent 683c9c5 commit 924798d
Showing 1 changed file with 2 additions and 2 deletions.
4 changes: 2 additions & 2 deletions src/common/SimilarToRegex.cpp
Expand Up @@ -110,7 +110,7 @@ namespace
options.set_log_errors(false);
options.set_dot_nl(true);
options.set_case_sensitive(!(flags & COMP_FLAG_CASE_INSENSITIVE));
options.set_utf8(!(flags & COMP_FLAG_LATIN));
options.set_encoding(flags & COMP_FLAG_LATIN ? RE2::Options::EncodingLatin1 : RE2::Options::EncodingUTF8);

re2::StringPiece sp((const char*) re2PatternStr.c_str(), re2PatternStr.length());
regexp = FB_NEW_POOL(pool) RE2(sp, options);
Expand Down Expand Up @@ -761,7 +761,7 @@ namespace
options.set_log_errors(false);
options.set_dot_nl(true);
options.set_case_sensitive(!(flags & COMP_FLAG_CASE_INSENSITIVE));
options.set_utf8(!(flags & COMP_FLAG_LATIN));
options.set_encoding(flags & COMP_FLAG_LATIN ? RE2::Options::EncodingLatin1 : RE2::Options::EncodingUTF8);

re2::StringPiece sp((const char*) finalRe2Pattern.c_str(), finalRe2Pattern.length());
regexp = FB_NEW_POOL(pool) RE2(sp, options);
Expand Down

0 comments on commit 924798d

Please sign in to comment.