Changeset View
Changeset View
Standalone View
Standalone View
src/net.cpp
Show First 20 Lines • Show All 2,520 Lines • ▼ Show 20 Lines | bool CConnman::Start(CScheduler &scheduler, const Options &connOptions) { | ||||
// Process messages | // Process messages | ||||
threadMessageHandler = | threadMessageHandler = | ||||
std::thread(&TraceThread<std::function<void()>>, "msghand", | std::thread(&TraceThread<std::function<void()>>, "msghand", | ||||
std::function<void()>( | std::function<void()>( | ||||
std::bind(&CConnman::ThreadMessageHandler, this))); | std::bind(&CConnman::ThreadMessageHandler, this))); | ||||
// Dump network addresses | // Dump network addresses | ||||
scheduler.scheduleEvery(std::bind(&CConnman::DumpData, this), | scheduler.scheduleEvery( | ||||
[this]() { | |||||
this->DumpData(); | |||||
return true; | |||||
}, | |||||
DUMP_ADDRESSES_INTERVAL * 1000); | DUMP_ADDRESSES_INTERVAL * 1000); | ||||
return true; | return true; | ||||
} | } | ||||
class CNetCleanup { | class CNetCleanup { | ||||
public: | public: | ||||
CNetCleanup() {} | CNetCleanup() {} | ||||
▲ Show 20 Lines • Show All 557 Lines • Show Last 20 Lines |