From 305c74d5163c5e344a675d39ca2394a9e45bd2c2 Mon Sep 17 00:00:00 2001 From: Aaron Brashears Date: Fri, 2 Feb 2007 17:28:58 +0000 Subject: Result of svn merge -r57264:57370 svn+ssh://svn/svn/linden/branches/adroit.r40-68 into release. --- indra/llxml/llcontrol.cpp | 10 +++++----- indra/llxml/llxmlnode.cpp | 30 +++++++++++++++--------------- indra/llxml/llxmlparser.cpp | 12 ++++++------ indra/llxml/llxmlparser.h | 2 +- 4 files changed, 27 insertions(+), 27 deletions(-) (limited to 'indra/llxml') diff --git a/indra/llxml/llcontrol.cpp b/indra/llxml/llcontrol.cpp index a9651fafc7..da6302b27c 100644 --- a/indra/llxml/llcontrol.cpp +++ b/indra/llxml/llcontrol.cpp @@ -580,7 +580,7 @@ U32 LLControlGroup::loadFromFileLegacy(const LLString& filename, BOOL require_de llifstream file; S32 version; - file.open(filename.c_str()); + file.open(filename.c_str()); /*Flawfinder: ignore*/ if (!file) { @@ -610,7 +610,7 @@ U32 LLControlGroup::loadFromFileLegacy(const LLString& filename, BOOL require_de if (name.substr(0,2) == "//") { // This is a comment. - char buffer[MAX_STRING]; + char buffer[MAX_STRING]; /*Flawfinder: ignore*/ file.getline(buffer, MAX_STRING); continue; } @@ -624,7 +624,7 @@ U32 LLControlGroup::loadFromFileLegacy(const LLString& filename, BOOL require_de if (!name.empty()) { //read in to end of line - char buffer[MAX_STRING]; + char buffer[MAX_STRING]; /*Flawfinder: ignore*/ file.getline(buffer, MAX_STRING); llwarns << "LLControlGroup::loadFromFile() : Trying to set \"" << name << "\", setting doesn't exist." << llendl; } @@ -690,7 +690,7 @@ U32 LLControlGroup::loadFromFileLegacy(const LLString& filename, BOOL require_de break; case TYPE_BOOLEAN: { - char boolstring[256]; + char boolstring[256]; /*Flawfinder: ignore*/ BOOL valid = FALSE; BOOL initial = FALSE; @@ -1048,7 +1048,7 @@ U32 LLControlGroup::saveToFile(const LLString& filename, BOOL nondefault_only) } llofstream file; - file.open(filename.c_str()); + file.open(filename.c_str()); /*Flawfinder: ignore*/ if (!file.is_open()) { diff --git a/indra/llxml/llxmlnode.cpp b/indra/llxml/llxmlnode.cpp index 7d77fa8be7..0789ec6842 100644 --- a/indra/llxml/llxmlnode.cpp +++ b/indra/llxml/llxmlnode.cpp @@ -542,7 +542,7 @@ bool LLXMLNode::parseFile( LLXMLNode* defaults_tree) { // Read file - FILE* fp = LLFile::fopen(filename.c_str(), "rb"); + FILE* fp = LLFile::fopen(filename.c_str(), "rb"); /* Flawfinder: ignore */ if (fp == NULL) { node = new LLXMLNode(); @@ -1846,12 +1846,12 @@ U32 LLXMLNode::getUUIDValue(U32 expected_length, LLUUID *array) LLUUID uuid_value; value_string = skipWhitespace(value_string); - if (strlen(value_string) < (UUID_STR_LENGTH-1)) + if (strlen(value_string) < (UUID_STR_LENGTH-1)) /* Flawfinder: ignore */ { break; } - char uuid_string[UUID_STR_LENGTH]; - memcpy(uuid_string, value_string, (UUID_STR_LENGTH-1)); + char uuid_string[UUID_STR_LENGTH]; /* Flawfinder: ignore */ + memcpy(uuid_string, value_string, (UUID_STR_LENGTH-1)); /* Flawfinder: ignore */ uuid_string[(UUID_STR_LENGTH-1)] = 0; if (!LLUUID::parseUUID(uuid_string, &uuid_value)) @@ -2136,18 +2136,18 @@ void LLXMLNode::setFloatValue(U32 length, const F32 *array, Encoding encoding, U LLString new_value; if (encoding == ENCODING_DEFAULT || encoding == ENCODING_DECIMAL) { - char format_string[10]; + char format_string[10]; /* Flawfinder: ignore */ if (precision > 0) { if (precision > 25) { precision = 25; } - sprintf(format_string, "%%.%dg", precision); + snprintf(format_string, sizeof(format_string), "%%.%dg", precision); /* Flawfinder: ignore */ } else { - sprintf(format_string, "%%g"); + snprintf(format_string, sizeof(format_string), "%%g"); /* Flawfinder: ignore */ } for (U32 pos=0; pos 0) { if (precision > 25) { precision = 25; } - sprintf(format_string, "%%.%dg", precision); + snprintf(format_string, sizeof(format_string), "%%.%dg", precision); /* Flawfinder: ignore */ } else { - sprintf(format_string, "%%g"); + snprintf(format_string, sizeof(format_string), "%%g"); /* Flawfinder: ignore */ } for (U32 pos=0; posmName->mString; - for (U32 pos=0; posmLength; ++pos) { const char *node_name = node_array[pos]->mName->mString; - for (U32 pos2=0; pos2