Fix typos in SBBreakpoint::GetThreadIndex()/GetThreadName(), and test sequences
for the two API calls.


git-svn-id: https://llvm.org/svn/llvm-project/llvdb/trunk@121898 91177308-0d34-0410-b5e6-96231b3b80d8
diff --git a/source/API/SBBreakpoint.cpp b/source/API/SBBreakpoint.cpp
index 238229c..8954683 100644
--- a/source/API/SBBreakpoint.cpp
+++ b/source/API/SBBreakpoint.cpp
@@ -314,14 +314,14 @@
     if (m_opaque_sp)
     {
         const ThreadSpec *thread_spec = m_opaque_sp->GetOptions()->GetThreadSpec();
-        if (thread_spec == NULL)
+        if (thread_spec != NULL)
             thread_idx = thread_spec->GetIndex();
     }
     LogSP log(lldb_private::GetLogIfAllCategoriesSet (LIBLLDB_LOG_API));
     if (log)
         log->Printf ("SBBreakpoint(%p)::GetThreadIndex () => %u", m_opaque_sp.get(), thread_idx);
 
-    return UINT32_MAX;
+    return thread_idx;
 }
     
 
@@ -343,7 +343,7 @@
     if (m_opaque_sp)
     {
         const ThreadSpec *thread_spec = m_opaque_sp->GetOptions()->GetThreadSpec();
-        if (thread_spec == NULL)
+        if (thread_spec != NULL)
             name = thread_spec->GetName();
     }
     LogSP log(lldb_private::GetLogIfAllCategoriesSet (LIBLLDB_LOG_API));