summaryrefslogtreecommitdiffstats
diff options
context:
space:
mode:
authorJim Ingham <jingham@apple.com>2013-01-23 23:14:13 +0000
committerJim Ingham <jingham@apple.com>2013-01-23 23:14:13 +0000
commit8bebe00a24aaecf1ef40995da7bc0a399a0e9678 (patch)
tree6ce5ddac2c7a4c980af17c9a40ff858e08a73e3f
parent8879c43a536cc5623c6b5260a038930f01e2176c (diff)
downloadbcm5719-llvm-8bebe00a24aaecf1ef40995da7bc0a399a0e9678.tar.gz
bcm5719-llvm-8bebe00a24aaecf1ef40995da7bc0a399a0e9678.zip
Check for NULL breakpoint option thread name & queue name before comparing their values to the new value.
<rdar://problem/13065198> llvm-svn: 173308
-rw-r--r--lldb/source/Breakpoint/Breakpoint.cpp6
1 files changed, 4 insertions, 2 deletions
diff --git a/lldb/source/Breakpoint/Breakpoint.cpp b/lldb/source/Breakpoint/Breakpoint.cpp
index 0b88625fe9e..1a7911f4a65 100644
--- a/lldb/source/Breakpoint/Breakpoint.cpp
+++ b/lldb/source/Breakpoint/Breakpoint.cpp
@@ -242,7 +242,8 @@ Breakpoint::GetThreadIndex() const
void
Breakpoint::SetThreadName (const char *thread_name)
{
- if (::strcmp (m_options.GetThreadSpec()->GetName(), thread_name) == 0)
+ if (m_options.GetThreadSpec()->GetName() != NULL
+ && ::strcmp (m_options.GetThreadSpec()->GetName(), thread_name) == 0)
return;
m_options.GetThreadSpec()->SetName (thread_name);
@@ -261,7 +262,8 @@ Breakpoint::GetThreadName () const
void
Breakpoint::SetQueueName (const char *queue_name)
{
- if (::strcmp (m_options.GetThreadSpec()->GetQueueName(), queue_name) == 0)
+ if (m_options.GetThreadSpec()->GetQueueName() != NULL
+ && ::strcmp (m_options.GetThreadSpec()->GetQueueName(), queue_name) == 0)
return;
m_options.GetThreadSpec()->SetQueueName (queue_name);
OpenPOWER on IntegriCloud