summaryrefslogtreecommitdiffstats
path: root/lldb/source/Target/SectionLoadList.cpp
diff options
context:
space:
mode:
Diffstat (limited to 'lldb/source/Target/SectionLoadList.cpp')
-rw-r--r--lldb/source/Target/SectionLoadList.cpp19
1 files changed, 19 insertions, 0 deletions
diff --git a/lldb/source/Target/SectionLoadList.cpp b/lldb/source/Target/SectionLoadList.cpp
index 96713c6ea79..82f52f9db1b 100644
--- a/lldb/source/Target/SectionLoadList.cpp
+++ b/lldb/source/Target/SectionLoadList.cpp
@@ -25,6 +25,25 @@ using namespace lldb;
using namespace lldb_private;
+SectionLoadList::SectionLoadList (const SectionLoadList& rhs) :
+ m_addr_to_sect(),
+ m_sect_to_addr(),
+ m_mutex (Mutex::eMutexTypeRecursive)
+{
+ Mutex::Locker locker(rhs.m_mutex);
+ m_addr_to_sect = rhs.m_addr_to_sect;
+ m_sect_to_addr = rhs.m_sect_to_addr;
+}
+
+void
+SectionLoadList::operator=(const SectionLoadList &rhs)
+{
+ Mutex::Locker lhs_locker (m_mutex);
+ Mutex::Locker rhs_locker (rhs.m_mutex);
+ m_addr_to_sect = rhs.m_addr_to_sect;
+ m_sect_to_addr = rhs.m_sect_to_addr;
+}
+
bool
SectionLoadList::IsEmpty() const
{
OpenPOWER on IntegriCloud