diff options
Diffstat (limited to '')
-rw-r--r-- | linden/indra/llui/llkeywords.cpp | 24 |
1 files changed, 12 insertions, 12 deletions
diff --git a/linden/indra/llui/llkeywords.cpp b/linden/indra/llui/llkeywords.cpp index fd224d8..05ec652 100644 --- a/linden/indra/llui/llkeywords.cpp +++ b/linden/indra/llui/llkeywords.cpp | |||
@@ -73,10 +73,10 @@ BOOL LLKeywords::loadFromFile( const LLString& filename ) | |||
73 | // File header | 73 | // File header |
74 | 74 | ||
75 | const S32 BUFFER_SIZE = 1024; | 75 | const S32 BUFFER_SIZE = 1024; |
76 | char buffer[BUFFER_SIZE]; | 76 | char buffer[BUFFER_SIZE]; /* Flawfinder: ignore */ |
77 | 77 | ||
78 | llifstream file; | 78 | llifstream file; |
79 | file.open(filename.c_str()); | 79 | file.open(filename.c_str()); /* Flawfinder: ignore */ |
80 | if( file.fail() ) | 80 | if( file.fail() ) |
81 | { | 81 | { |
82 | llinfos << "LLKeywords::loadFromFile() Unable to open file: " << filename << llendl; | 82 | llinfos << "LLKeywords::loadFromFile() Unable to open file: " << filename << llendl; |
@@ -114,34 +114,34 @@ BOOL LLKeywords::loadFromFile( const LLString& filename ) | |||
114 | while (!file.eof()) | 114 | while (!file.eof()) |
115 | { | 115 | { |
116 | file.getline( buffer, BUFFER_SIZE ); | 116 | file.getline( buffer, BUFFER_SIZE ); |
117 | if( !strncmp( buffer, SOL_COMMENT, strlen(SOL_COMMENT) ) ) | 117 | if( !strncmp( buffer, SOL_COMMENT, strlen(SOL_COMMENT) ) ) /* Flawfinder: ignore */ |
118 | { | 118 | { |
119 | continue; | 119 | continue; |
120 | } | 120 | } |
121 | else | 121 | else |
122 | if( !strncmp( buffer, SOL_WORD, strlen(SOL_WORD) ) ) | 122 | if( !strncmp( buffer, SOL_WORD, strlen(SOL_WORD) ) ) /* Flawfinder: ignore */ |
123 | { | 123 | { |
124 | cur_color = readColor( buffer + strlen(SOL_WORD) ); | 124 | cur_color = readColor( buffer + strlen(SOL_WORD) ); /* Flawfinder: ignore */ |
125 | cur_type = LLKeywordToken::WORD; | 125 | cur_type = LLKeywordToken::WORD; |
126 | continue; | 126 | continue; |
127 | } | 127 | } |
128 | else | 128 | else |
129 | if( !strncmp( buffer, SOL_LINE, strlen(SOL_LINE) ) ) | 129 | if( !strncmp( buffer, SOL_LINE, strlen(SOL_LINE) ) ) /* Flawfinder: ignore */ |
130 | { | 130 | { |
131 | cur_color = readColor( buffer + strlen(SOL_LINE) ); | 131 | cur_color = readColor( buffer + strlen(SOL_LINE) ); /* Flawfinder: ignore */ |
132 | cur_type = LLKeywordToken::LINE; | 132 | cur_type = LLKeywordToken::LINE; |
133 | continue; | 133 | continue; |
134 | } | 134 | } |
135 | else | 135 | else |
136 | if( !strncmp( buffer, SOL_TWO_SIDED_DELIMITER, strlen(SOL_TWO_SIDED_DELIMITER) ) ) | 136 | if( !strncmp( buffer, SOL_TWO_SIDED_DELIMITER, strlen(SOL_TWO_SIDED_DELIMITER) ) ) /* Flawfinder: ignore */ |
137 | { | 137 | { |
138 | cur_color = readColor( buffer + strlen(SOL_TWO_SIDED_DELIMITER) ); | 138 | cur_color = readColor( buffer + strlen(SOL_TWO_SIDED_DELIMITER) ); /* Flawfinder: ignore */ |
139 | cur_type = LLKeywordToken::TWO_SIDED_DELIMITER; | 139 | cur_type = LLKeywordToken::TWO_SIDED_DELIMITER; |
140 | continue; | 140 | continue; |
141 | } | 141 | } |
142 | if( !strncmp( buffer, SOL_ONE_SIDED_DELIMITER, strlen(SOL_ONE_SIDED_DELIMITER) ) ) | 142 | if( !strncmp( buffer, SOL_ONE_SIDED_DELIMITER, strlen(SOL_ONE_SIDED_DELIMITER) ) ) /* Flawfinder: ignore */ |
143 | { | 143 | { |
144 | cur_color = readColor( buffer + strlen(SOL_ONE_SIDED_DELIMITER) ); | 144 | cur_color = readColor( buffer + strlen(SOL_ONE_SIDED_DELIMITER) ); /* Flawfinder: ignore */ |
145 | cur_type = LLKeywordToken::ONE_SIDED_DELIMITER; | 145 | cur_type = LLKeywordToken::ONE_SIDED_DELIMITER; |
146 | continue; | 146 | continue; |
147 | } | 147 | } |
@@ -220,7 +220,7 @@ LLColor3 LLKeywords::readColor( const LLString& s ) | |||
220 | F32 r, g, b; | 220 | F32 r, g, b; |
221 | r = g = b = 0.0f; | 221 | r = g = b = 0.0f; |
222 | S32 read = sscanf(s.c_str(), "%f, %f, %f]", &r, &g, &b ); | 222 | S32 read = sscanf(s.c_str(), "%f, %f, %f]", &r, &g, &b ); |
223 | if( read != 3 ) | 223 | if( read != 3 ) /* Flawfinder: ignore */ |
224 | { | 224 | { |
225 | llinfos << " poorly formed color in keyword file" << llendl; | 225 | llinfos << " poorly formed color in keyword file" << llendl; |
226 | } | 226 | } |