[Lldb-commits] [lldb] r122984 - in /lldb/trunk/source/Plugins/Process/Linux: LinuxThread.cpp LinuxThread.h

Stephen Wilson wilsons at start.ca
Thu Jan 6 16:10:43 PST 2011


Author: wilsons
Date: Thu Jan  6 18:10:43 2011
New Revision: 122984

URL: http://llvm.org/viewvc/llvm-project?rev=122984&view=rev
Log:
Fix a few small issues in r122981 to ensure compilation on Linux.

Also, call GetProcess instead of CalculateProcess as the latter is morally part
of the ExecutionContextScope API.


Modified:
    lldb/trunk/source/Plugins/Process/Linux/LinuxThread.cpp
    lldb/trunk/source/Plugins/Process/Linux/LinuxThread.h

Modified: lldb/trunk/source/Plugins/Process/Linux/LinuxThread.cpp
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/Process/Linux/LinuxThread.cpp?rev=122984&r1=122983&r2=122984&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/Process/Linux/LinuxThread.cpp (original)
+++ lldb/trunk/source/Plugins/Process/Linux/LinuxThread.cpp Thu Jan  6 18:10:43 2011
@@ -33,8 +33,8 @@
 ProcessMonitor &
 LinuxThread::GetMonitor()
 {
-    ProcessLinux *process = static_cast<ProcessLinux*>(CalculateProcess());
-    return process->GetMonitor();
+    ProcessLinux &process = static_cast<ProcessLinux&>(GetProcess());
+    return process.GetMonitor();
 }
 
 void
@@ -51,6 +51,8 @@
 lldb::RegisterContextSP
 LinuxThread::GetRegisterContext()
 {
+    ProcessLinux &process = static_cast<ProcessLinux&>(GetProcess());
+
     if (!m_reg_context_sp)
     {
         ArchSpec arch = process.GetTarget().GetArchitecture();
@@ -66,7 +68,7 @@
             break;
         }
     }
-    return m_reg_context_sp    
+    return m_reg_context_sp;
 }
 
 bool

Modified: lldb/trunk/source/Plugins/Process/Linux/LinuxThread.h
URL: http://llvm.org/viewvc/llvm-project/lldb/trunk/source/Plugins/Process/Linux/LinuxThread.h?rev=122984&r1=122983&r2=122984&view=diff
==============================================================================
--- lldb/trunk/source/Plugins/Process/Linux/LinuxThread.h (original)
+++ lldb/trunk/source/Plugins/Process/Linux/LinuxThread.h Thu Jan  6 18:10:43 2011
@@ -48,7 +48,7 @@
     RestoreSaveFrameZero(const RegisterCheckpoint &checkpoint);
 
     virtual lldb::RegisterContextSP
-    CreateRegisterContextForFrame (StackFrame *frame);
+    CreateRegisterContextForFrame (lldb_private::StackFrame *frame);
 
     //--------------------------------------------------------------------------
     // These methods form a specialized interface to linux threads.
@@ -66,7 +66,7 @@
     {
         if (!m_reg_context_sp)
             GetRegisterContext();
-        return (RegisterContextLinux *)m_reg_context_sp.get()
+        return (RegisterContextLinux *)m_reg_context_sp.get();
     }
     
     std::auto_ptr<lldb_private::StackFrame> m_frame_ap;





More information about the lldb-commits mailing list