diff --git a/source/eventcore/drivers/posix/sockets.d b/source/eventcore/drivers/posix/sockets.d index dd9e00a..12247a4 100644 --- a/source/eventcore/drivers/posix/sockets.d +++ b/source/eventcore/drivers/posix/sockets.d @@ -955,14 +955,15 @@ private int getSocketError() version (Windows) return WSAGetLastError(); else return errno; } + private int getBacklogSize() @trusted @nogc nothrow { int backlog = 128; - version(linux) + version (linux) { import core.stdc.stdio : fclose, fopen, fscanf; auto somaxconn = fopen("/proc/sys/net/core/somaxconn", "re"); - if(somaxconn) + if (somaxconn) { int tmp; if (fscanf(somaxconn, "%d", &tmp) == 1)