summaryrefslogtreecommitdiffstats
path: root/lldb/source/Core/FileSpecList.cpp
diff options
context:
space:
mode:
authorZachary Turner <zturner@google.com>2016-02-24 21:26:47 +0000
committerZachary Turner <zturner@google.com>2016-02-24 21:26:47 +0000
commit47c03462f52a13ba79ac257e7de88a74dd23f5d7 (patch)
tree33978281912ffc0642edc2732b252f5bb4698176 /lldb/source/Core/FileSpecList.cpp
parent72c57f49c4b5638626f5a6ff91187f33976c321f (diff)
downloadbcm5719-llvm-47c03462f52a13ba79ac257e7de88a74dd23f5d7.tar.gz
bcm5719-llvm-47c03462f52a13ba79ac257e7de88a74dd23f5d7.zip
Some fixes for case insensitive paths on Windows.
Paths on Windows are not case-sensitive. Because of this, if a file is called main.cpp, you should be able to set a breakpoint on it by using the name Main.cpp. In an ideal world, you could just tell people to match the case, but in practice this can be a real problem as it requires you to know whether the person who compiled the program ran "clang++ main.cpp" or "clang++ Main.cpp", both of which would work, regardless of what the file was actually called. This fixes http://llvm.org/pr22667 Patch by Petr Hons Differential Revision: http://reviews.llvm.org/D17492 Reviewed by: zturner llvm-svn: 261771
Diffstat (limited to 'lldb/source/Core/FileSpecList.cpp')
-rw-r--r--lldb/source/Core/FileSpecList.cpp3
1 files changed, 2 insertions, 1 deletions
diff --git a/lldb/source/Core/FileSpecList.cpp b/lldb/source/Core/FileSpecList.cpp
index 4b1c991c6be..191b6e13995 100644
--- a/lldb/source/Core/FileSpecList.cpp
+++ b/lldb/source/Core/FileSpecList.cpp
@@ -119,7 +119,8 @@ FileSpecList::FindFileIndex (size_t start_idx, const FileSpec &file_spec, bool f
{
if (compare_filename_only)
{
- if (m_files[idx].GetFilename() == file_spec.GetFilename())
+ if (ConstString::Equals(m_files[idx].GetFilename(), file_spec.GetFilename(),
+ file_spec.IsCaseSensitive() || m_files[idx].IsCaseSensitive()))
return idx;
}
else
OpenPOWER on IntegriCloud