diff --git a/include/mapnik/renderer_common/process_point_symbolizer.hpp b/include/mapnik/renderer_common/process_point_symbolizer.hpp index 22778a312..d48e1862d 100644 --- a/include/mapnik/renderer_common/process_point_symbolizer.hpp +++ b/include/mapnik/renderer_common/process_point_symbolizer.hpp @@ -41,15 +41,10 @@ void render_point_symbolizer(point_symbolizer const &sym, F render_marker) { std::string filename = get(sym, keys::file, feature, common.vars_); - boost::optional marker; - if (!filename.empty()) - { - marker = marker_cache::instance().find(filename, true); - } - else - { - marker.reset(std::make_shared()); - } + boost::optional marker = filename.empty() + ? std::make_shared() + : marker_cache::instance().find(filename, true); + if (marker) { double opacity = get(sym,keys::opacity,feature, common.vars_, 1.0);