diff options
author | Pavel Labath <labath@google.com> | 2017-01-16 12:15:42 +0000 |
---|---|---|
committer | Pavel Labath <labath@google.com> | 2017-01-16 12:15:42 +0000 |
commit | 238169db60fe37a801a9bdb9174c2a0085286036 (patch) | |
tree | 6f5cbe220d01c40f2307a68e4ca1e582f6b66b11 /lldb/source/Host/common/FileSpec.cpp | |
parent | 2ef3887d28132707a81f4b087285b653963b15cd (diff) | |
download | llvm-238169db60fe37a801a9bdb9174c2a0085286036.zip llvm-238169db60fe37a801a9bdb9174c2a0085286036.tar.gz llvm-238169db60fe37a801a9bdb9174c2a0085286036.tar.bz2 |
Fix windows unit tests
The unit test I added in the previous commit discovered a bug in
PrependPathComponent on windows -- it was calling SetFile with the host native
path syntax, whereas it should be explicitly specifying the path syntax (as
AppendPathComponent does). This fixes it.
llvm-svn: 292106
Diffstat (limited to 'lldb/source/Host/common/FileSpec.cpp')
-rw-r--r-- | lldb/source/Host/common/FileSpec.cpp | 2 |
1 files changed, 1 insertions, 1 deletions
diff --git a/lldb/source/Host/common/FileSpec.cpp b/lldb/source/Host/common/FileSpec.cpp index 578ca9f..26503d2 100644 --- a/lldb/source/Host/common/FileSpec.cpp +++ b/lldb/source/Host/common/FileSpec.cpp @@ -1277,7 +1277,7 @@ void FileSpec::PrependPathComponent(llvm::StringRef component) { std::string result = join_path_components(m_syntax, {component, m_directory.GetStringRef(), m_filename.GetStringRef()}); - SetFile(result, resolve); + SetFile(result, resolve, m_syntax); } void FileSpec::PrependPathComponent(const FileSpec &new_path) { |