diff options
author | Greg Clayton <gclayton@apple.com> | 2012-01-30 09:04:36 +0000 |
---|---|---|
committer | Greg Clayton <gclayton@apple.com> | 2012-01-30 09:04:36 +0000 |
commit | acdbe8163798063d625caa28c4137af0f222d328 (patch) | |
tree | 686b3282ccf3bfaab1038932499a4caeefdd0ab4 /lldb/source/API/SBModule.cpp | |
parent | 2962e7b6569c9d1188045c88122649550f37393e (diff) | |
download | bcm5719-llvm-acdbe8163798063d625caa28c4137af0f222d328.tar.gz bcm5719-llvm-acdbe8163798063d625caa28c4137af0f222d328.zip |
lldb::SBTarget and lldb::SBProcess are now thread hardened. They both still
contain shared pointers to the lldb_private::Target and lldb_private::Process
objects respectively as we won't want the target or process just going away.
Also cleaned up the lldb::SBModule to remove dangerous pointer accessors.
For any code the public API files, we should always be grabbing shared
pointers to any objects for the current class, and any other classes prior
to running code with them.
llvm-svn: 149238
Diffstat (limited to 'lldb/source/API/SBModule.cpp')
-rw-r--r-- | lldb/source/API/SBModule.cpp | 37 |
1 files changed, 3 insertions, 34 deletions
diff --git a/lldb/source/API/SBModule.cpp b/lldb/source/API/SBModule.cpp index 28180fce63a..6200cc6c839 100644 --- a/lldb/source/API/SBModule.cpp +++ b/lldb/source/API/SBModule.cpp @@ -193,49 +193,18 @@ SBModule::operator != (const SBModule &rhs) const return false; } -lldb::ModuleSP & -SBModule::operator *() -{ - return m_opaque_sp; -} - -lldb_private::Module * -SBModule::operator ->() -{ - return m_opaque_sp.get(); -} - -const lldb_private::Module * -SBModule::operator ->() const -{ - return m_opaque_sp.get(); -} - -lldb_private::Module * -SBModule::get() -{ - return m_opaque_sp.get(); -} - -const lldb_private::Module * -SBModule::get() const -{ - return m_opaque_sp.get(); -} - -const lldb::ModuleSP & -SBModule::get_sp() const +ModuleSP +SBModule::GetSP () const { return m_opaque_sp; } void -SBModule::SetModule (const lldb::ModuleSP& module_sp) +SBModule::SetSP (const ModuleSP &module_sp) { m_opaque_sp = module_sp; } - SBAddress SBModule::ResolveFileAddress (lldb::addr_t vm_addr) { |