aboutsummaryrefslogtreecommitdiffstatshomepage
path: root/linden/indra/newview/llvotree.cpp
diff options
context:
space:
mode:
authorJacek Antonelli2008-09-06 18:24:57 -0500
committerJacek Antonelli2008-09-06 18:25:07 -0500
commit798d367d54a6c6379ad355bd8345fa40e31e7fe9 (patch)
tree1921f1708cd0240648c97bc02df2c2ab5f2fc41e /linden/indra/newview/llvotree.cpp
parentSecond Life viewer sources 1.20.15 (diff)
downloadmeta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.zip
meta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.tar.gz
meta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.tar.bz2
meta-impy-798d367d54a6c6379ad355bd8345fa40e31e7fe9.tar.xz
Second Life viewer sources 1.21.0-RC
Diffstat (limited to 'linden/indra/newview/llvotree.cpp')
-rw-r--r--linden/indra/newview/llvotree.cpp10
1 files changed, 4 insertions, 6 deletions
diff --git a/linden/indra/newview/llvotree.cpp b/linden/indra/newview/llvotree.cpp
index 993c2a0..c86803d 100644
--- a/linden/indra/newview/llvotree.cpp
+++ b/linden/indra/newview/llvotree.cpp
@@ -232,7 +232,7 @@ void LLVOTree::initClass()
232 232
233 if (!success) 233 if (!success)
234 { 234 {
235 LLString name; 235 std::string name;
236 static LLStdStringHandle name_string = LLXmlTree::addAttributeString("name"); 236 static LLStdStringHandle name_string = LLXmlTree::addAttributeString("name");
237 tree_def->getFastAttributeString(name_string, name); 237 tree_def->getFastAttributeString(name_string, name);
238 llwarns << "Incomplete definition of tree " << name << llendl; 238 llwarns << "Incomplete definition of tree " << name << llendl;
@@ -240,22 +240,20 @@ void LLVOTree::initClass()
240 } 240 }
241 241
242 BOOL have_all_trees = TRUE; 242 BOOL have_all_trees = TRUE;
243 LLString err; 243 std::string err;
244 char buffer[10]; /* Flawfinder: ignore */
245 244
246 for (S32 i=0;i<sMaxTreeSpecies;++i) 245 for (S32 i=0;i<sMaxTreeSpecies;++i)
247 { 246 {
248 if (!sSpeciesTable.count(i)) 247 if (!sSpeciesTable.count(i))
249 { 248 {
250 snprintf(buffer,10," %d",i); /* Flawfinder: ignore */ 249 err.append(llformat(" %d",i));
251 err.append(buffer);
252 have_all_trees = FALSE; 250 have_all_trees = FALSE;
253 } 251 }
254 } 252 }
255 253
256 if (!have_all_trees) 254 if (!have_all_trees)
257 { 255 {
258 LLStringBase<char>::format_map_t args; 256 LLStringUtil::format_map_t args;
259 args["[SPECIES]"] = err; 257 args["[SPECIES]"] = err;
260 gViewerWindow->alertXml("ErrorUndefinedTrees", args ); 258 gViewerWindow->alertXml("ErrorUndefinedTrees", args );
261 } 259 }