Skip to content

Commit

Permalink
Stop using PO6_DTOR_ERROR.
Browse files Browse the repository at this point in the history
  • Loading branch information
rescrv committed May 9, 2012
1 parent 0072312 commit 3ab1af0
Showing 1 changed file with 3 additions and 42 deletions.
45 changes: 3 additions & 42 deletions include/e/striped_lock.h
Original file line number Diff line number Diff line change
Expand Up @@ -60,20 +60,7 @@ striped_lock<T> :: striped_lock(size_t striping)
template <typename T>
striped_lock<T> :: ~striped_lock() throw ()
{
try
{
delete[] m_locks;
}
catch (...)
{
try
{
PO6_DTOR_ERROR("Unable to destruct striped lock.");
}
catch (...)
{
}
}
delete[] m_locks;
}

template <typename T>
Expand All @@ -99,20 +86,7 @@ striped_lock<T> :: hold :: hold(striped_lock<T>* l, size_t stripe_num)
template <typename T>
striped_lock<T> :: hold :: ~hold() throw ()
{
try
{
m_l->m_locks[m_stripe].unlock();
}
catch (...)
{
try
{
PO6_DTOR_ERROR("Unable to release striped_lock with RAII.");
}
catch (...)
{
}
}
m_l->m_locks[m_stripe].unlock();
}

template <typename T>
Expand Down Expand Up @@ -152,20 +126,7 @@ striped_lock<T> :: multihold :: ~multihold() throw ()
{
for (size_t i = 0; i < m_stripes.size(); ++i)
{
try
{
m_l->m_locks[m_stripes[i]].unlock();
}
catch (...)
{
try
{
PO6_DTOR_ERROR("Unable to release striped_lock with RAII.");
}
catch (...)
{
}
}
m_l->m_locks[m_stripes[i]].unlock();
}
}

Expand Down

0 comments on commit 3ab1af0

Please sign in to comment.