MCPcopy Create free account
hub / github.com/PurpleI2P/i2pd / SetTestingState

Method SetTestingState

libi2pd/SSU2Session.cpp:2860–2871  ·  view source on GitHub ↗

Source from the content-addressed store, hash-verified

2858 }
2859
2860 void SSU2Session::SetTestingState (bool testing) const
2861 {
2862 if (m_Address)
2863 {
2864 if (m_Address->IsV4 ())
2865 i2p::context.SetTesting (testing);
2866 else if (m_Address->IsV6 ())
2867 i2p::context.SetTestingV6 (testing);
2868 }
2869 if (!testing)
2870 m_Server.AdjustTimeOffset (0, nullptr); // reset time offset when testing is over
2871 }
2872
2873 size_t SSU2Session::CreateAddressBlock (uint8_t * buf, size_t len, const boost::asio::ip::udp::endpoint& ep)
2874 {

Callers

nothing calls this directly

Calls 5

SetTestingMethod · 0.80
SetTestingV6Method · 0.80
AdjustTimeOffsetMethod · 0.80
IsV4Method · 0.45
IsV6Method · 0.45

Tested by

no test coverage detected