Index: lldb/trunk/include/lldb/Host/FileSpec.h =================================================================== --- lldb/trunk/include/lldb/Host/FileSpec.h +++ lldb/trunk/include/lldb/Host/FileSpec.h @@ -669,8 +669,14 @@ SetFile (const char *path, bool resolve_path, PathSyntax syntax = ePathSyntaxHostNative); void + SetFile(const char *path, bool resolve_path, ArchSpec arch); + + void SetFile(const std::string &path, bool resolve_path, PathSyntax syntax = ePathSyntaxHostNative); + void + SetFile(const std::string &path, bool resolve_path, ArchSpec arch); + bool IsResolved () const { Index: lldb/trunk/source/Host/common/FileSpec.cpp =================================================================== --- lldb/trunk/source/Host/common/FileSpec.cpp +++ lldb/trunk/source/Host/common/FileSpec.cpp @@ -345,11 +345,26 @@ } void +FileSpec::SetFile(const char *pathname, bool resolve, ArchSpec arch) +{ + return SetFile(pathname, resolve, + arch.GetTriple().isOSWindows() + ? ePathSyntaxWindows + : ePathSyntaxPosix); +} + +void FileSpec::SetFile(const std::string &pathname, bool resolve, PathSyntax syntax) { return SetFile(pathname.c_str(), resolve, syntax); } +void +FileSpec::SetFile(const std::string &pathname, bool resolve, ArchSpec arch) +{ + return SetFile(pathname.c_str(), resolve, arch); +} + //---------------------------------------------------------------------- // Convert to pointer operator. This allows code to check any FileSpec // objects to see if they contain anything valid using code such as: Index: lldb/trunk/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp =================================================================== --- lldb/trunk/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp +++ lldb/trunk/source/Plugins/Process/gdb-remote/GDBRemoteCommunicationClient.cpp @@ -2301,7 +2301,7 @@ return false; std::string cwd; response.GetHexByteString(cwd); - working_dir.SetFile(cwd, false); + working_dir.SetFile(cwd, false, GetHostArchitecture()); return !cwd.empty(); } return false;