mirror of
https://github.com/intel/llvm.git
synced 2026-01-16 05:32:28 +08:00
Check for NULL breakpoint option thread name & queue name before comparing their values to the new value.
<rdar://problem/13065198> llvm-svn: 173308
This commit is contained in:
@@ -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);
|
||||
|
||||
Reference in New Issue
Block a user