Browse Source

[Qt] Add TRY_LOCK back to peertablemodel

pull/145/head
Cozz Lovan 10 years ago
parent
commit
9297763dad
  1. 10
      src/qt/peertablemodel.cpp

10
src/qt/peertablemodel.cpp

@ -75,8 +75,14 @@ public:
}
// Try to retrieve the CNodeStateStats for each node.
BOOST_FOREACH(CNodeCombinedStats &stats, cachedNodeStats)
stats.fNodeStateStatsAvailable = GetNodeStateStats(stats.nodeStats.nodeid, stats.nodeStateStats);
{
TRY_LOCK(cs_main, lockMain);
if (lockMain)
{
BOOST_FOREACH(CNodeCombinedStats &stats, cachedNodeStats)
stats.fNodeStateStatsAvailable = GetNodeStateStats(stats.nodeStats.nodeid, stats.nodeStateStats);
}
}
if (sortColumn >= 0)
// sort cacheNodeStats (use stable sort to prevent rows jumping around unneceesarily)

Loading…
Cancel
Save