| 409 | } |
| 410 | |
| 411 | void RouterContext::PublishNTCP2Address (std::shared_ptr<i2p::data::RouterInfo::Address> address, |
| 412 | int port, bool publish, int version) const |
| 413 | { |
| 414 | if (!address) return; |
| 415 | if (!port && !address->port) port = SelectRandomPort (); |
| 416 | if (port) address->port = port; |
| 417 | address->published = publish; |
| 418 | address->v = version; |
| 419 | memcpy (address->i, m_NTCP2Keys->iv, 16); |
| 420 | } |
| 421 | |
| 422 | void RouterContext::PublishNTCP2Address (int port, bool publish, bool v4, bool v6, bool ygg, int version) |
| 423 | { |
no test coverage detected