Add -Wextra and fix the warnings.
[dcpomatic.git] / src / lib / util.cc
index a68496e94260bf90b5ab6bda607f709470d393a8..45965385c6c9b4f5e4bdb9202be0671b2335f720 100644 (file)
@@ -428,6 +428,7 @@ Socket::check ()
 void
 Socket::connect (asio::ip::basic_resolver_entry<asio::ip::tcp> const & endpoint, int timeout)
 {
+       _deadline.expires_from_now (posix_time::seconds (timeout));
        system::error_code ec = asio::error::would_block;
        _socket.async_connect (endpoint, lambda::var(ec) = lambda::_1);
        do {