mirror of
https://github.com/SChernykh/p2pool.git
synced 2025-01-03 09:19:24 +00:00
Removed unnecessary lock
This commit is contained in:
parent
20b3886bfb
commit
d4388bf9c0
1 changed files with 0 additions and 7 deletions
|
@ -103,9 +103,6 @@ BlockTemplate& BlockTemplate::operator=(const BlockTemplate& b)
|
|||
|
||||
WriteLock lock(m_lock);
|
||||
|
||||
// b.m_lock should already be locked here, but try to lock it for reading anyway
|
||||
const int lock_result = uv_rwlock_tryrdlock(&b.m_lock);
|
||||
|
||||
m_pool = b.m_pool;
|
||||
m_templateId = b.m_templateId;
|
||||
m_blockTemplateBlob = b.m_blockTemplateBlob;
|
||||
|
@ -139,10 +136,6 @@ BlockTemplate& BlockTemplate::operator=(const BlockTemplate& b)
|
|||
m_knapsack.clear();
|
||||
#endif
|
||||
|
||||
if (lock_result == 0) {
|
||||
uv_rwlock_rdunlock(&b.m_lock);
|
||||
}
|
||||
|
||||
return *this;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue