make SVG path parser stricter by failing if not all input parsed ref #3225
This commit is contained in:
parent
fd6e7704a1
commit
479a657437
1 changed files with 3 additions and 3 deletions
|
@ -44,9 +44,9 @@ namespace mapnik { namespace svg {
|
||||||
svg_path_grammar<iterator_type,skip_type,PathType> g(p);
|
svg_path_grammar<iterator_type,skip_type,PathType> g(p);
|
||||||
iterator_type first = wkt;
|
iterator_type first = wkt;
|
||||||
iterator_type last = wkt + std::strlen(wkt);
|
iterator_type last = wkt + std::strlen(wkt);
|
||||||
return qi::phrase_parse(first, last, g, skip_type());
|
bool status = qi::phrase_parse(first, last, g, skip_type());
|
||||||
|
return (status && (first == last));
|
||||||
}
|
}
|
||||||
|
|
||||||
template bool parse_path<svg_converter_type>(const char*, svg_converter_type&);
|
template bool parse_path<svg_converter_type>(const char*, svg_converter_type&);
|
||||||
|
|
||||||
}}
|
}}
|
||||||
|
|
Loading…
Reference in a new issue