Work around non-numeric input

This commit is contained in:
Tom MacWright 2012-01-26 17:40:02 -05:00
parent d466b49671
commit 4c46385bf6

View file

@ -72,7 +72,11 @@ void memory_datasource::push(feature_ptr feature)
std::map<std::string,mapnik::value>::const_iterator it = fprops.begin();
std::map<std::string,mapnik::value>::const_iterator end = fprops.end();
for (; it != end; ++it) {
try {
accumulators_[it->first](it->second.to_double());
} catch(boost::bad_lexical_cast &) {
// string values are not accumulated.
}
}
features_.push_back(feature);
}