From: Mikko Rasa Date: Fri, 27 Sep 2019 21:37:41 +0000 (+0300) Subject: Use an IPv6 socket for Http::Server X-Git-Url: http://git.tdb.fi/?a=commitdiff_plain;h=0fa2b313e2272eee27fe9a968ca339c26443210d;p=libs%2Fnet.git Use an IPv6 socket for Http::Server --- diff --git a/source/http/server.cpp b/source/http/server.cpp index f985bf9..20d2b39 100644 --- a/source/http/server.cpp +++ b/source/http/server.cpp @@ -18,11 +18,11 @@ namespace Msp { namespace Http { Server::Server(unsigned port): - sock(Net::INET), + sock(Net::INET6), event_disp(0) { sock.signal_data_available.connect(sigc::mem_fun(this, &Server::data_available)); - RefPtr addr = Net::resolve("*", format("%d", port)); + RefPtr addr = Net::resolve("*", format("%d", port), Net::INET6); sock.listen(*addr, 8); }