diff options
| author | Dimitry Andric <dim@FreeBSD.org> | 2017-04-16 16:04:10 +0000 | 
|---|---|---|
| committer | Dimitry Andric <dim@FreeBSD.org> | 2017-04-16 16:04:10 +0000 | 
| commit | 74a628f776edb588bff8f8f5cc16eac947c9d631 (patch) | |
| tree | dc32e010ac4902621e5a279bfeb48628f7f0e166 /source/Target/ProcessLaunchInfo.cpp | |
| parent | afed7be32164a598f8172282c249af7266c48b46 (diff) | |
Diffstat (limited to 'source/Target/ProcessLaunchInfo.cpp')
| -rw-r--r-- | source/Target/ProcessLaunchInfo.cpp | 10 | 
1 files changed, 5 insertions, 5 deletions
diff --git a/source/Target/ProcessLaunchInfo.cpp b/source/Target/ProcessLaunchInfo.cpp index 92d9371b541f..7de55f2fdcf9 100644 --- a/source/Target/ProcessLaunchInfo.cpp +++ b/source/Target/ProcessLaunchInfo.cpp @@ -14,15 +14,17 @@  // Other libraries and framework includes  // Project includes  #include "lldb/Core/Debugger.h" -#include "lldb/Core/Log.h"  #include "lldb/Host/Config.h"  #include "lldb/Host/FileSystem.h"  #include "lldb/Host/HostInfo.h"  #include "lldb/Target/FileAction.h"  #include "lldb/Target/ProcessLaunchInfo.h"  #include "lldb/Target/Target.h" +#include "lldb/Utility/Log.h" +#include "lldb/Utility/StreamString.h"  #include "llvm/Support/ConvertUTF.h" +#include "llvm/Support/FileSystem.h"  #if !defined(_WIN32)  #include <limits.h> @@ -368,10 +370,8 @@ bool ProcessLaunchInfo::ConvertArgumentsForLaunchingInShell(            if (working_dir) {              new_path += working_dir.GetPath();            } else { -            char current_working_dir[PATH_MAX]; -            const char *cwd = -                getcwd(current_working_dir, sizeof(current_working_dir)); -            if (cwd && cwd[0]) +            llvm::SmallString<64> cwd; +            if (! llvm::sys::fs::current_path(cwd))                new_path += cwd;            }            std::string curr_path;  | 
