Only accept world updates from upstreams.
This commit is contained in:
parent
e6840a1863
commit
e4b6611201
3 changed files with 33 additions and 9 deletions
|
@ -215,6 +215,20 @@ public:
|
|||
return _moons;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return Moon IDs we are waiting for from seeds
|
||||
*/
|
||||
inline std::vector<uint64_t> moonsWanted() const
|
||||
{
|
||||
Mutex::Lock _l(_upstreams_m);
|
||||
std::vector<uint64_t> mw;
|
||||
for(std::vector< std::pair<uint64_t,Address> >::const_iterator s(_moonSeeds.begin());s!=_moonSeeds.end();++s) {
|
||||
if (std::find(mw.begin(),mw.end(),s->first) == mw.end())
|
||||
mw.push_back(s->first);
|
||||
}
|
||||
return mw;
|
||||
}
|
||||
|
||||
/**
|
||||
* @return Current planet
|
||||
*/
|
||||
|
|
Loading…
Add table
Add a link
Reference in a new issue