Rietveld Code Review Tool
Help | Bug tracker | Discussion group | Source code

Unified Diff: compiled/filter/RegExpFilter.cpp

Issue 29556737: Issue 5141 - Convert filter match to C++ (Closed) Base URL: https://hg.adblockplus.org/adblockpluscore/
Patch Set: Cleanup. Fixed the bindings to export what we actually need. Created Sept. 27, 2017, 3:27 p.m.
Use n/p to move between diff chunks; N/P to move between comments.
Jump to:
View side-by-side diff with in-line comments
Download patch
« no previous file with comments | « compiled/filter/Matcher.cpp ('k') | compiled/library.h » ('j') | no next file with comments »
Expand Comments ('e') | Collapse Comments ('c') | Show Comments Hide Comments ('s')
Index: compiled/filter/RegExpFilter.cpp
===================================================================
--- a/compiled/filter/RegExpFilter.cpp
+++ b/compiled/filter/RegExpFilter.cpp
@@ -310,17 +310,17 @@
if (!error.empty())
return Type::INVALID;
if (data.mPatternEnd - data.mPatternStart >= 2 &&
text[data.mPatternStart] == u'/' &&
text[data.mPatternEnd - 1] == u'/')
{
data.SetRegExp(GenerateRegExp(DependentString(text, data.mPatternStart + 1,
- data.mPatternEnd - data.mPatternStart - 2), data.mMatchCase));
+ data.mPatternEnd - data.mPatternStart - 2), data.mMatchCase, false));
if (data.mRegexpId == -1)
{
error.reset(u"filter_invalid_regexp"_str);
return Type::INVALID;
}
}
return type;
@@ -386,12 +386,12 @@
!IsActiveOnDomain(docDomain, sitekey))
{
return false;
}
if (!mData.RegExpParsingDone())
{
const OwnedString pattern(mData.GetRegExpSource(mText));
- mData.SetRegExp(GenerateRegExp(RegExpFromSource(pattern), mData.mMatchCase));
+ mData.SetRegExp(GenerateRegExp(RegExpFromSource(pattern), mData.mMatchCase, false));
}
return TestRegExp(mData.mRegexpId, location);
}
« no previous file with comments | « compiled/filter/Matcher.cpp ('k') | compiled/library.h » ('j') | no next file with comments »

Powered by Google App Engine
This is Rietveld