diff options
author | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2011-05-20 19:24:12 +0000 |
---|---|---|
committer | Argyrios Kyrtzidis <akyrtzi@gmail.com> | 2011-05-20 19:24:12 +0000 |
commit | ac8bc12cd15fd677565a79b7877890aceb74069a (patch) | |
tree | 546c4117f825dc9116b4d974671eee6d86740dd2 /llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp | |
parent | 91f1d247363ee1fbc567a0dbea94bc6bfd76db02 (diff) | |
download | llvm-ac8bc12cd15fd677565a79b7877890aceb74069a.zip llvm-ac8bc12cd15fd677565a79b7877890aceb74069a.tar.gz llvm-ac8bc12cd15fd677565a79b7877890aceb74069a.tar.bz2 |
Add asserts in StringRef to make sure we avoid undefined behavior:
-strlen should not be called with NULL. Also guarantee that StringRef's Length is 0 if Data is NULL.
-memcmp should not be called with NULL (even if size is 0)
Patch by Matthieu Monrocq!
llvm-svn: 131747
Diffstat (limited to 'llvm/lib/CodeGen/TargetLoweringObjectFileImpl.cpp')
0 files changed, 0 insertions, 0 deletions