summaryrefslogtreecommitdiffstats
path: root/llvm/lib
diff options
context:
space:
mode:
authorKeno Fischer <kfischer@college.harvard.edu>2014-08-15 01:39:12 +0000
committerKeno Fischer <kfischer@college.harvard.edu>2014-08-15 01:39:12 +0000
commit070db177bd530a935237097ee53e4480d90cf830 (patch)
tree75aa0b7c3e1630612d7d65be81aad53496c6498a /llvm/lib
parent3755e17decf67497a0f57c18d4c483385fed04ab (diff)
downloadbcm5719-llvm-070db177bd530a935237097ee53e4480d90cf830.tar.gz
bcm5719-llvm-070db177bd530a935237097ee53e4480d90cf830.zip
Make sure CallExpr::getLocStart doesn't segfault
Summary: When the CallExpr passed to Sema::ConvertArgumentsForCall has all default parameters, and the number of actual arguments passed is zero, this function will segfault in the call to Call->getLocStart() if the Callee has an invalid getLocStart(), the reason being that since ConvertArgumentsForCall has set the correct number of arguments, but has not filled them in yet, getLocStart() will try to access the first (not yet existent) argument and thus segfaults. This fixes that by making getLocStart return an invalid source location if the queried argument is NULL rather than segfaulting. Reviewers: rnk Reviewed By: rnk Subscribers: cfe-commits Differential Revision: http://reviews.llvm.org/D4917 llvm-svn: 215686
Diffstat (limited to 'llvm/lib')
0 files changed, 0 insertions, 0 deletions
OpenPOWER on IntegriCloud