From 2a24584d45523851874f7858eaf5d44e32037315 Mon Sep 17 00:00:00 2001 From: orignal Date: Mon, 4 Jul 2022 23:00:16 -0400 Subject: [PATCH] set SSU2 port if not specified --- daemon/Daemon.cpp | 6 ++++++ 1 file changed, 6 insertions(+) diff --git a/daemon/Daemon.cpp b/daemon/Daemon.cpp index c6e6465a..1afa25e9 100644 --- a/daemon/Daemon.cpp +++ b/daemon/Daemon.cpp @@ -257,6 +257,12 @@ namespace util if (published) { uint16_t ssu2port; i2p::config::GetOption("ssu2.port", ssu2port); + if (!ssu2port) + { + ssu2port = port; + bool ssu; i2p::config::GetOption("ssu", ssu); + if (ssu) ssu2port++; + } i2p::context.PublishSSU2Address (ssu2port, true, ipv4, ipv6); // publish } else