diff --git a/src/forwarder.hpp b/src/forwarder.hpp index 3698999d1a4ca942237190f20b010a1c619bf5d6..295b5133d172d4fcf4f3c09deea8538b9381077a 100644 --- a/src/forwarder.hpp +++ b/src/forwarder.hpp @@ -31,7 +31,11 @@ public: ptrOutbound = nullptr; // TODO else if (outboundConfig.starts_with("misc")) ptrOutbound = nullptr; // TODO + } + ~Forwarder() { + if (ptrInbound) delete ptrInbound; + if (ptrOutbound) delete ptrOutbound; } diff --git a/src/protocols/plain.hpp b/src/protocols/plain.hpp index fd0a327f4aa78e898dfaf9ffcfbab4260f9d9754..9fd0e74b8dabcad7147a7f5819563c4ce875f7e0 100644 --- a/src/protocols/plain.hpp +++ b/src/protocols/plain.hpp @@ -35,7 +35,7 @@ namespace Protocols { char buffer[DGRAM_BUFFER_SIZE]; // WARN: If you want to modify this program to work for both TCP and UDP, PLEASE use rlib::sockIO::recv instead of fixed buffer. - rlog.info("PlainListener listening [{}]:{} ...", listenAddr, listenPort); + rlog.info("PlainListener listening InboundPort [{}]:{} ...", listenAddr, listenPort); while (true) { // ... // epoll