X-Git-Url: http://g0dil.de/git?a=blobdiff_plain;f=Examples%2FTCPClientServer%2Fserver.cc;h=54a2040c6f75f1ec4678fcb1d9fd67aae30a0c8c;hb=81ffa1c459b96dd44472bcef37e1e373934ee138;hp=a3b0374dc4589fbcfd349f8073cd1648aedcc5e0;hpb=9357448dc66bc9acfd3bd8db423deb75bcd6a2c4;p=senf.git diff --git a/Examples/TCPClientServer/server.cc b/Examples/TCPClientServer/server.cc index a3b0374..54a2040 100644 --- a/Examples/TCPClientServer/server.cc +++ b/Examples/TCPClientServer/server.cc @@ -29,8 +29,8 @@ #include #include "Scheduler/Scheduler.hh" #include "Utils/membind.hh" -#include "Socket/TCPSocketHandle.hh" -#include "Socket/INetAddressing.hh" +#include "Socket/Protocols/INet/TCPSocketHandle.hh" +#include "Socket/Protocols/INet/INetAddressing.hh" class Server @@ -38,8 +38,8 @@ class Server senf::TCPv4ServerSocketHandle serverSock; public: - Server(std::string const & host, unsigned int port) - : serverSock(senf::INet4Address(host, port)) {} + Server(senf::INet4Address const & host, unsigned int port) + : serverSock(senf::INet4SocketAddress(host, port)) {} void run() { @@ -75,7 +75,7 @@ private: int main(int argc, char const * argv[]) { try { - Server myServer ("127.0.0.1", 4243); + Server myServer (senf::INet4Address::Loopback, 4243); myServer.run(); } catch (std::exception const & ex) { @@ -83,3 +83,14 @@ int main(int argc, char const * argv[]) } return 0; } + + +// Local Variables: +// mode: c++ +// fill-column: 100 +// c-file-style: "senf" +// indent-tabs-mode: nil +// ispell-local-dictionary: "american" +// compile-command: "scons -u" +// comment-column: 40 +// End: