From 727d42fa670a546e035462ce06232d9202cb6beb Mon Sep 17 00:00:00 2001 From: "Tristan B. Kildaire" Date: Tue, 3 Nov 2020 10:41:32 +0200 Subject: [PATCH] Added debug print for the address the listener's socket is bound to --- source/dnetd/dlistener.d | 4 ++++ 1 file changed, 4 insertions(+) diff --git a/source/dnetd/dlistener.d b/source/dnetd/dlistener.d index 3ab1231..b952523 100644 --- a/source/dnetd/dlistener.d +++ b/source/dnetd/dlistener.d @@ -4,6 +4,8 @@ import std.socket; import dnetd.dserver; import core.thread; import dnetd.dconnection; +import gogga; +import std.conv : to; public final class DListener : Thread { @@ -28,6 +30,7 @@ public final class DListener : Thread // Address address = addressInfo.address; + /* TODO: Check AF_FAMILY (can only be INET,INET6,UNIX) */ /* TODO: Check SocketType (can only be STREAM) */ /* TODO: Check Protocol, can only be RAW (assuming UNIX) or TCP */ @@ -35,6 +38,7 @@ public final class DListener : Thread /* Create the Socket and bind it */ serverSocket = new Socket(addressInfo); + gprintln("New listener started with address "~to!(string)(addressInfo)); /* Start the connection dequeue thread */ start();