mirror of
https://github.com/c64scene-ar/llvm-6502.git
synced 2024-08-21 03:29:40 +00:00
Fix FileCheck crash when fuzzy scanning starting at the end of the file.
git-svn-id: https://llvm.org/svn/llvm-project/llvm/trunk@90065 91177308-0d34-0410-b5e6-96231b3b80d8
This commit is contained in:
parent
cd188e9665
commit
a76a7883b5
@ -398,7 +398,7 @@ void Pattern::PrintFailureInfo(const SourceMgr &SM, StringRef Buffer,
|
||||
}
|
||||
}
|
||||
|
||||
if (BestQuality < 50) {
|
||||
if (Best != StringRef::npos && BestQuality < 50) {
|
||||
// Print the "possible intended match here" line if we found something
|
||||
// reasonable.
|
||||
SM.PrintMessage(SMLoc::getFromPointer(Buffer.data() + Best),
|
||||
|
Loading…
Reference in New Issue
Block a user