1
0
mirror of https://github.com/binary-kitchen/doorlockd synced 2024-12-22 10:24:26 +01:00

Only listening on localhost

This commit is contained in:
Ralf Ramsauer 2015-05-18 22:22:59 +02:00
parent f99ed93f29
commit 8b2a0ea4ca

View File

@ -69,7 +69,7 @@ class server
public:
server(boost::asio::io_service& io_service, short port)
: _acceptor(io_service, tcp::endpoint(tcp::v4(), port)),
: _acceptor(io_service, tcp::endpoint(boost::asio::ip::address::from_string("127.0.0.1"), port)),
_socket(io_service)
{
do_accept();
@ -79,7 +79,6 @@ private:
void do_accept()
{
_acceptor.async_accept(_socket,
[this](boost::system::error_code ec)
{