[PATCH] D25279: [ELF] - Do not crash on large output.
George Rimar via llvm-commits
llvm-commits at lists.llvm.org
Thu Oct 6 14:02:14 PDT 2016
grimar added inline comments.
> rafael wrote in Writer.cpp:1223
> I wonder how many cases there can be where overflow and if there is a general solution.
>
> How was this crashing before?
Yes, that is a problem, solution is not general :( Crash was because of overflow of Off that is used to calculate FileSize.
So file created was little and it then crashes in writeTo during writing output sections.
We do not check end of buffer there. Probably it can be a that "general solution". I`ll try to do domething tomorrow with that.
https://reviews.llvm.org/D25279
More information about the llvm-commits
mailing list