summaryrefslogtreecommitdiff
path: root/lldb/source/Host/posix/FileSystem.cpp
diff options
context:
space:
mode:
authorZachary Turner <zturner@google.com>2015-10-14 21:37:36 +0000
committerZachary Turner <zturner@google.com>2015-10-14 21:37:36 +0000
commit4eff2d3177caa7ddbe901d54619f483ed4323e1b (patch)
tree15dc969266976323f8766a1bf893b3de750f04c8 /lldb/source/Host/posix/FileSystem.cpp
parentefc23de4dd6b9066d83742c7e307067824ced69a (diff)
Make uses of /dev/null portable across OSes.
Most platforms have "/dev/null". Windows has "nul". Instead of hardcoding the string /dev/null at various places, make a constant that contains the correct value depending on the platform, and use that everywhere instead. llvm-svn: 250331
Diffstat (limited to 'lldb/source/Host/posix/FileSystem.cpp')
-rw-r--r--lldb/source/Host/posix/FileSystem.cpp3
1 files changed, 3 insertions, 0 deletions
diff --git a/lldb/source/Host/posix/FileSystem.cpp b/lldb/source/Host/posix/FileSystem.cpp
index b974c446b911..1f2e7db0e1e4 100644
--- a/lldb/source/Host/posix/FileSystem.cpp
+++ b/lldb/source/Host/posix/FileSystem.cpp
@@ -32,6 +32,9 @@
using namespace lldb;
using namespace lldb_private;
+const char *
+FileSystem::DEV_NULL = "/dev/null";
+
FileSpec::PathSyntax
FileSystem::GetNativePathSyntax()
{