Read corpus files as binary to avoid automatic conversions
Details
Details
Diff Detail
Diff Detail
- Build Status
Buildable 24641 Build 24640: arc lint + arc unit
Event Timeline
Comment Actions
Please take a look
This should fix crbug.com/902460
I didn't change the uses of ifstream in FuzzerDataFlowTrace.cpp and FuzzerMerge.cpp since they seem to be used on nonbinary files written by libFuzzer.
compiler-rt/lib/fuzzer/FuzzerIO.cpp | ||
---|---|---|
54 | I don't think it is 100% necessary to use binary for this line, but probably better safe than sorry. |
Comment Actions
I guess it might be worth adding the binary mode argument to FuzzerMerge.cpp and FuzzerDataFlowTrace.cpp as well, since apparently we may have some unexpected platform-dependent specifics when reading files.
Comment Actions
Do you think those files can contain binary? They look like they cannot to me.
Is there a test for this that fails on Windows?
Do you mean a test for this behavior that passes on Windows?
I don't think it is 100% necessary to use binary for this line, but probably better safe than sorry.