Add a sanity check in MemoryBuffer::getOpenFile() to make sure we don't hang
authorArgyrios Kyrtzidis <akyrtzi@gmail.com>
Tue, 13 Mar 2012 20:18:42 +0000 (20:18 +0000)
committerArgyrios Kyrtzidis <akyrtzi@gmail.com>
Tue, 13 Mar 2012 20:18:42 +0000 (20:18 +0000)
commitb9153bacd05f4e31f8d841a54ee035abea5b3f41
tree3285cb174a9fb2f7f9af322796cb3a50df18123d
parente4c972d8643a340e822c419eea2461c1357fb015
Add a sanity check in MemoryBuffer::getOpenFile() to make sure we don't hang
if the passed in FileSize is inaccurate.

rdar://11034179

git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@152662 91177308-0d34-0410-b5e6-96231b3b80d8
lib/Support/MemoryBuffer.cpp