| 8 | #include "cmXMLParser.h" |
| 9 | |
| 10 | extern "C" int LLVMFuzzerTestOneInput(uint8_t const* data, size_t size) |
| 11 | { |
| 12 | char test_file[] = "libfuzzer.xml"; |
| 13 | |
| 14 | FILE* fp = fopen(test_file, "wb"); |
| 15 | if (!fp) |
| 16 | return 0; |
| 17 | fwrite(data, size, 1, fp); |
| 18 | fclose(fp); |
| 19 | |
| 20 | cmXMLParser parser; |
| 21 | if (!parser.ParseFile(test_file)) { |
| 22 | return 1; |
| 23 | } |
| 24 | |
| 25 | remove(test_file); |
| 26 | return 0; |
| 27 | } |
nothing calls this directly
no test coverage detected
searching dependent graphs…