mirror of
https://github.com/SChernykh/p2pool.git
synced 2025-04-16 18:41:54 +00:00
Fixed Coverity errors
This commit is contained in:
parent
a75cf652de
commit
24f2ed2f81
2 changed files with 4 additions and 2 deletions
|
@ -37,7 +37,9 @@ class RandomBytes
|
|||
public:
|
||||
RandomBytes() : rng(RandomDeviceSeed::instance), dist(0, 255)
|
||||
{
|
||||
uv_mutex_init_checked(&m);
|
||||
if (uv_mutex_init(&m) != 0) {
|
||||
abort();
|
||||
}
|
||||
|
||||
// Diffuse the initial state in case it has low quality
|
||||
rng.discard(10000);
|
||||
|
|
|
@ -178,7 +178,7 @@ void P2PServer::clear_cached_blocks()
|
|||
return;
|
||||
}
|
||||
|
||||
for (auto it : *m_cachedBlocks) {
|
||||
for (const auto& it : *m_cachedBlocks) {
|
||||
delete it.second;
|
||||
}
|
||||
|
||||
|
|
Loading…
Reference in a new issue