diff options
| author | David Majnemer <david.majnemer@gmail.com> | 2014-10-25 11:40:40 +0000 |
|---|---|---|
| committer | David Majnemer <david.majnemer@gmail.com> | 2014-10-25 11:40:40 +0000 |
| commit | d3c3e78ac17602420ca05b1ce1ed7d20ba9c5ede (patch) | |
| tree | f1557da8c7b007803d97eb97c40f6aa684e195bc /llvm/lib/Transforms/Utils/LowerInvoke.cpp | |
| parent | a63672665f98c6a9df6da6fe7359a3d0a732d1a6 (diff) | |
| download | bcm5719-llvm-d3c3e78ac17602420ca05b1ce1ed7d20ba9c5ede.tar.gz bcm5719-llvm-d3c3e78ac17602420ca05b1ce1ed7d20ba9c5ede.zip | |
Lex: Fix an invalid access into a SmallString
We would crash because we used operator[] to access past the end of a
SmallString. This occured because our token had length zero.
Instead, form the pointer using .data() and arithmetic. This is safe
because this forms a one-past-the-end pointer and it is only used to
compare with another one-past-the-end pointer.
This fixes PR21379.
llvm-svn: 220614
Diffstat (limited to 'llvm/lib/Transforms/Utils/LowerInvoke.cpp')
0 files changed, 0 insertions, 0 deletions

