From a408a84fb01af62ca382cec9083cdf0cb28022ef Mon Sep 17 00:00:00 2001 From: artemp Date: Mon, 19 Jan 2015 22:04:21 +0100 Subject: [PATCH] ignore invalid bounding boxes from "geometry": null --- include/mapnik/json/extract_bounding_box_grammar.hpp | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/include/mapnik/json/extract_bounding_box_grammar.hpp b/include/mapnik/json/extract_bounding_box_grammar.hpp index 6395e0797..f2638fec6 100644 --- a/include/mapnik/json/extract_bounding_box_grammar.hpp +++ b/include/mapnik/json/extract_bounding_box_grammar.hpp @@ -77,7 +77,7 @@ struct push_box_impl template void operator() (T0 & boxes, T1 const& begin, T2 const& box, T3 const& range) const { - boxes.emplace_back(box, std::make_pair(std::distance(begin, range.begin()), std::distance(range.begin(), range.end()))); + if (box.valid()) boxes.emplace_back(box, std::make_pair(std::distance(begin, range.begin()), std::distance(range.begin(), range.end()))); } };