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/API/SBPlatform.cpp | |
| parent | afed7be32164a598f8172282c249af7266c48b46 (diff) | |
Diffstat (limited to 'source/API/SBPlatform.cpp')
| -rw-r--r-- | source/API/SBPlatform.cpp | 6 |
1 files changed, 4 insertions, 2 deletions
diff --git a/source/API/SBPlatform.cpp b/source/API/SBPlatform.cpp index 6085cef32064..0f1b99236a71 100644 --- a/source/API/SBPlatform.cpp +++ b/source/API/SBPlatform.cpp @@ -13,11 +13,13 @@ #include "lldb/API/SBLaunchInfo.h" #include "lldb/API/SBUnixSignals.h" #include "lldb/Core/ArchSpec.h" -#include "lldb/Core/Error.h" #include "lldb/Host/File.h" #include "lldb/Interpreter/Args.h" #include "lldb/Target/Platform.h" #include "lldb/Target/Target.h" +#include "lldb/Utility/Error.h" + +#include "llvm/Support/FileSystem.h" #include <functional> @@ -363,7 +365,7 @@ SBError SBPlatform::Put(SBFileSpec &src, SBFileSpec &dst) { if (src.Exists()) { uint32_t permissions = src.ref().GetPermissions(); if (permissions == 0) { - if (src.ref().GetFileType() == FileSpec::eFileTypeDirectory) + if (llvm::sys::fs::is_directory(src.ref().GetPath())) permissions = eFilePermissionsDirectoryDefault; else permissions = eFilePermissionsFileDefault; |
