diff options
author | Enrico Granata <egranata@apple.com> | 2012-11-03 00:09:46 +0000 |
---|---|---|
committer | Enrico Granata <egranata@apple.com> | 2012-11-03 00:09:46 +0000 |
commit | 80fcdd429f33b2058dc94e8891ddb54ac0e1628e (patch) | |
tree | da1c5ea1db4b2d0f833d27261241684a93807cac /lldb/source/Host/common/FileSpec.cpp | |
parent | 5852e3b800b76d7bc4ec010069e1f5e293ca257c (diff) | |
download | bcm5719-llvm-80fcdd429f33b2058dc94e8891ddb54ac0e1628e.tar.gz bcm5719-llvm-80fcdd429f33b2058dc94e8891ddb54ac0e1628e.zip |
Caught two cases where we were passing a Stream* without checking for NULL
llvm-svn: 167342
Diffstat (limited to 'lldb/source/Host/common/FileSpec.cpp')
-rw-r--r-- | lldb/source/Host/common/FileSpec.cpp | 11 |
1 files changed, 7 insertions, 4 deletions
diff --git a/lldb/source/Host/common/FileSpec.cpp b/lldb/source/Host/common/FileSpec.cpp index d356ff68495..5109695ad20 100644 --- a/lldb/source/Host/common/FileSpec.cpp +++ b/lldb/source/Host/common/FileSpec.cpp @@ -524,10 +524,13 @@ FileSpec::Equal (const FileSpec& a, const FileSpec& b, bool full) void FileSpec::Dump(Stream *s) const { - m_directory.Dump(s); - if (m_directory) - s->PutChar('/'); - m_filename.Dump(s); + if (s) + { + m_directory.Dump(s); + if (m_directory) + s->PutChar('/'); + m_filename.Dump(s); + } } //------------------------------------------------------------------ |