| 287 | // --------- XMLUtil ----------- // |
| 288 | |
| 289 | const char* XMLUtil::ReadBOM( const char* p, bool* bom ) |
| 290 | { |
| 291 | TIXMLASSERT( p ); |
| 292 | TIXMLASSERT( bom ); |
| 293 | *bom = false; |
| 294 | const unsigned char* pu = reinterpret_cast<const unsigned char*>(p); |
| 295 | // Check for BOM: |
| 296 | if ( *(pu+0) == TIXML_UTF_LEAD_0 |
| 297 | && *(pu+1) == TIXML_UTF_LEAD_1 |
| 298 | && *(pu+2) == TIXML_UTF_LEAD_2 ) { |
| 299 | *bom = true; |
| 300 | p += 3; |
| 301 | } |
| 302 | TIXMLASSERT( p ); |
| 303 | return p; |
| 304 | } |
| 305 | |
| 306 | |
| 307 | void XMLUtil::ConvertUTF32ToUTF8( unsigned long input, char* output, int* length ) |
nothing calls this directly
no outgoing calls
no test coverage detected