|
14 | 14 | // We think that these examples have bad domains. |
15 | 15 | std::set<std::string> bad_domains = {"http://./", "http://../", "http://foo.09.."}; |
16 | 16 |
|
17 | | -#ifdef _WIN32 |
18 | | -// Under Windows, we use get transitional IDN, but the spec is based on non-transitional. |
19 | | -std::set<std::string> exceptions = {"\x68\x74\x74\x70\x73\x3a\x2f\x2f\x66\x61\xc3\x9f\x2e\x45\x78\x41\x6d\x50\x6c\x45\x2f"}; |
20 | | -#endif |
21 | | - |
22 | 17 | // This function copies your input onto a memory buffer that |
23 | 18 | // has just the necessary size. This will entice tools to detect |
24 | 19 | // an out-of-bound access. |
@@ -311,9 +306,6 @@ bool urltestdata_encoding(const char* source) { |
311 | 306 | return false; |
312 | 307 | } |
313 | 308 | std::cout << "input='" << input << "' [" << input.size() << " bytes]" << std::endl; |
314 | | -#ifdef _WIN32 |
315 | | - if(exceptions.find(std::string(input)) != exceptions.end()) { std::cerr << "skipping "+element_string << std::endl; continue; } |
316 | | -#endif |
317 | 309 | std::string_view base; |
318 | 310 | ada::result base_url; |
319 | 311 | if (!object["base"].get(base)) { |
@@ -458,13 +450,13 @@ int main(int argc, char** argv) { |
458 | 450 | if(all_tests || name.find(filter) != std::string::npos) { |
459 | 451 | results[name] = toascii_encoding(); |
460 | 452 | } |
461 | | -#endif // _WIN32 |
| 453 | +#endif // ADA_HAS_ICU |
462 | 454 | name = "setters_tests_encoding("+std::string(SETTERS_TESTS_JSON)+")"; |
463 | 455 | if(all_tests || name.find(filter) != std::string::npos) { |
464 | 456 | results[name] = setters_tests_encoding(SETTERS_TESTS_JSON); |
465 | 457 | #if !ADA_HAS_ICU |
466 | 458 | results[name] = true; // we pretend. The setters fail under Windows due to IDN issues. |
467 | | -#endif // _WIN32 |
| 459 | +#endif // !ADA_HAS_ICU |
468 | 460 | } |
469 | 461 | name = "setters_tests_encoding("+std::string(ADA_SETTERS_TESTS_JSON)+")"; |
470 | 462 | if(all_tests || name.find(filter) != std::string::npos) { |
@@ -493,8 +485,6 @@ int main(int argc, char** argv) { |
493 | 485 | std::cout << "==============="<< std::endl; |
494 | 486 | #if ADA_HAS_ICU |
495 | 487 | std::cout << "We are using ICU."<< std::endl; |
496 | | -#elif defined(_WIN32) |
497 | | - std::cout << "We are using Microsoft's Normaliz."<< std::endl; |
498 | 488 | #else |
499 | 489 | std::cout << "ICU is unavailable and we have no feedback."<< std::endl; |
500 | 490 | #endif |
|
0 commit comments