only print failed face_set_ptr loading for fontsets if MAPNIK_LOG is defined - refs #1175

This commit is contained in:
Dane Springmeyer 2012-04-19 11:27:04 -07:00
parent 2b92f04926
commit 16a16b1818

View file

@ -304,16 +304,19 @@ public:
face_set_ptr face_set = boost::make_shared<font_face_set>(); face_set_ptr face_set = boost::make_shared<font_face_set>();
for (std::vector<std::string>::const_iterator name = names.begin(); name != names.end(); ++name) for (std::vector<std::string>::const_iterator name = names.begin(); name != names.end(); ++name)
{ {
if (face_ptr face = get_face(*name)) face_ptr face = get_face(*name);
if (face)
{ {
face_set->add(face); face_set->add(face);
} }
#ifdef MAPNIK_LOG
else else
{ {
MAPNIK_LOG_ERROR(font_engine_freetype) MAPNIK_LOG_DEBUG(font_engine_freetype)
<< "Failed to find face '" << *name << "Failed to find face '" << *name
<< "' in font set '" << fset.get_name() << "'\n"; << "' in font set '" << fset.get_name() << "'\n";
} }
#endif
} }
return face_set; return face_set;
} }