Commit Graph

2274 Commits

Author SHA1 Message Date
Christopher Kohlhoff
a2e070a79e Fix exception safety issue in hash_map. 2016-09-13 22:51:28 +10:00
Christopher Kohlhoff
b1b9e5c4a6 Add workaround for move-detection issue on MSVC 2015 Update 2. 2016-09-13 22:46:39 +10:00
Christopher Kohlhoff
2cde22623c Call SSL_COMP_free_compression_methods() on ssl cleanup.
This call is needed for OpenSSL >=1.0.2 and <1.1.0.
2016-09-13 21:59:03 +10:00
Christopher Kohlhoff
41cb2faa19 Additional libraries required to link Boost.Coroutine. 2016-09-11 12:51:04 +10:00
Christopher Kohlhoff
af9770ac49 Use new TLS methods on OpenSSL 1.1.0. 2016-09-11 12:49:17 +10:00
Christopher Kohlhoff
7249bcc143 Backward compatibility for code using OpenSSL < 1.1.0.
Some application code using asio::ssl::stream<> explicitly tests for the
SSL_R_SHORT_READ error. For compatibility, when using older versions of
OpenSSL we will define the ssl::error::stream_truncated to use this
value.
2016-09-11 12:49:09 +10:00
Christopher Kohlhoff
503b8bb172 Fix allocator usage to compile with g++ 6. 2016-09-11 07:52:23 +10:00
Christopher Kohlhoff
6cec69ea0c Disable speculative operations after a short read or write.
When using epoll, interpret a short read or write on a stream-oriented
socket as an indication that we should wait for a readiness event. After
this condition, speculative operations are disabled until we receive the
event notification from epoll.
2016-09-11 07:52:23 +10:00
Christopher Kohlhoff
c9e33cee0e New special concurrency hints. 2016-09-09 18:02:38 +10:00
Christopher Kohlhoff
6ef25d7722 The null_event must sleep for correct behaviour of timed run functions. 2016-09-09 14:33:44 +10:00
Christopher Kohlhoff
79e3edd257 Allow use_future support to compile when exceptions are disabled. 2016-09-09 14:33:44 +10:00
Christopher Kohlhoff
85e011bb43 Update socket iostreams to adhere to the TS. 2016-09-09 14:33:44 +10:00
Christopher Kohlhoff
a48d0b4dd8 Add move support for deadline_timer. 2016-09-06 09:19:24 +10:00
Christopher Kohlhoff
be2458a444 Enable getaddrinfo by default on Apple platforms.
The getaddrinfo function is now used by default unless Mac OS X 10.4 or
earlier is detected. Its use may also be explicitly disabled by defining
ASIO_DISABLE_GETADDRINFO.
2016-09-06 07:56:29 +10:00
Christopher Kohlhoff
276846097a Fix dynamic buffer consume() implementation. 2016-09-05 19:24:52 +10:00
Christopher Kohlhoff
7268a3f488 Clean up header inclusion of old services. 2016-09-04 14:39:46 +10:00
Christopher Kohlhoff
26a0c87849 Strip out deprecated, extension and old services code. 2016-09-04 14:13:19 +10:00
Christopher Kohlhoff
348e4bd236 Mark basic_streambuf, regex, and match condition overloads as extensions. 2016-09-04 13:42:16 +10:00
Christopher Kohlhoff
14676ca0a0 Remove redundant deprecated preprocessor test. 2016-09-04 13:41:31 +10:00
Christopher Kohlhoff
d02c77e708 Fix mismatched preprocessor comment. 2016-09-04 13:40:38 +10:00
Christopher Kohlhoff
a8f9b3cedc Fix MSVC Intellisense detection. 2016-09-03 21:35:22 +10:00
Christopher Kohlhoff
1aa65b56ca Minimise overloads of buffer_size() and buffer_copy().
The public interface is now specified in terms of buffer sequences. The
optimised overloads for const_buffer, mutable_buffer, etc. are now
implementation details.
2016-09-03 21:35:21 +10:00
Christopher Kohlhoff
0a109643e2 Add socket_base::max_listen_connections, deprecate max_connections. 2016-08-31 08:09:16 +10:00
Christopher Kohlhoff
37d0d474f2 Remove SSL_accept locking for OpenSSL 1.0 and later. 2016-08-29 09:51:55 +10:00
Christopher Kohlhoff
a9fa5bf248 Add limited support for regular file descriptors.
The epoll_reactor now supports the use of regular file descriptors with
posix::stream_descriptor, provided the I/O operations on them never fail
with EAGAIN or EWOULDBLOCK. If the descriptor cannot be added to the
epoll set using epoll_ctl, and errno is EPERM (indicating an unsupported
descriptor type), then no error condition is raised. Instead, any
operation which would require a trip through the reactor will fail.
2016-08-28 23:27:51 +10:00
Christopher Kohlhoff
0d78be17cf Regenerate documentation. 2016-08-28 12:10:10 +10:00
Christopher Kohlhoff
ec50a1b966 Use stable index ids. 2016-08-28 12:10:01 +10:00
Christopher Kohlhoff
e8f545460e Make deleted copy constructor and assignment operator private. 2016-08-28 11:45:50 +10:00
Christopher Kohlhoff
6f86878ff7 Explicitly construct return type in the dynamic buffers' data() member functions. 2016-08-28 10:15:27 +10:00
Christopher Kohlhoff
69e44a4cc6 Fix errors when OPENSSL_NO_DEPRECATED is defined. 2016-08-28 10:05:06 +10:00
Christopher Kohlhoff
443bc17d13 Automatically handle glibc variant of strerror_r without #ifdefs. 2016-08-28 10:02:42 +10:00
Christopher Kohlhoff
0c262fe076 Only apply firewall workaround when getsockname outputs INADDR_ANY. 2016-08-28 10:02:42 +10:00
Christopher Kohlhoff
d636aafe8a Ensure new headers are self-contained. 2016-08-28 10:02:42 +10:00
Christopher Kohlhoff
a00d184641 Update const_buffer and mutable_buffer operator+ to strictly adhere to TS. 2016-08-28 10:02:41 +10:00
Christopher Kohlhoff
3909c65a11 Add operator+= to const_buffer and mutable_buffer. 2016-08-28 10:02:41 +10:00
Christopher Kohlhoff
c65f3bd163 Refactor the detail::consuming_buffers template.
The consuming_buffers template, which is used internally by the composed
read and write operations, did not correctly satisfy the buffer sequence
requirements as its iterator was not bidirectional. Rather than acting
as a proxy buffer sequence, the reworked consuming_buffers template
instead produces fixed-size buffer sequences as required.
2016-08-28 10:02:41 +10:00
Marcel Raad
062b19c97b Add compatibility with OpenSSL 1.1
- SSLv2 has been completely removed from OpenSSL, even without OPENSSL_NO_SSL2
- there is a new threading API without locking callbacks
- struct SSL_CTX has been made opaque and must be used via accessor functions
- some cleanup functions have been removed
2016-08-26 12:42:50 +02:00
Christopher Kohlhoff
0999ec96d1 Regenerate documentation. 2016-08-25 09:19:31 +10:00
Christopher Kohlhoff
87ecd843d3 Disable io_context::work when ASIO_NO_DEPRECATED is defined. 2016-08-25 09:19:31 +10:00
Christopher Kohlhoff
cbcaf259cf Update requirements, overview and quick reference. 2016-08-25 09:19:30 +10:00
Christopher Kohlhoff
4d199b84de Add tsify.pl script. 2016-08-25 08:19:39 +10:00
Christopher Kohlhoff
24bdca2061 Deprecate error_code returns on synchronous operations. 2016-08-25 08:19:38 +10:00
Christopher Kohlhoff
c1f2a3b735 Add ASIO_NO_EXTENSIONS to disable the non-TS parts of the API. 2016-08-25 08:19:38 +10:00
Christopher Kohlhoff
0f6478c9c9 Update copyright notices. 2016-08-25 07:24:35 +10:00
Christopher Kohlhoff
7b8815ea41 Make unit tests work when ASIO_NO_DEPRECATED is defined. 2016-08-25 07:24:35 +10:00
Christopher Kohlhoff
7ea623bbc4 Update asio/ts/* header files to match networking TS. 2016-08-25 07:24:35 +10:00
Christopher Kohlhoff
5316fbba3b Don't include deadline_timer headers when Boost.Date_Time is disabled. 2016-08-25 07:24:34 +10:00
Christopher Kohlhoff
16120e1bd7 New const/mutable buffer sequence requirements.
The buffer sequence requirements are now defined in terms of new functions
buffer_sequence_begin() and buffer_sequence_end(). As a result, the
mutable_buffer and const_buffer classes satisfy the buffer sequence
requirements. The mutable_buffers_1 and const_buffers_1 classes have been
deprecated.
2016-08-25 07:24:34 +10:00
Christopher Kohlhoff
6176a69c81 Rename header to 'net' to match TS. 2016-08-25 07:24:34 +10:00
Christopher Kohlhoff
cacd7e9a8e Add timed run functions to the io_context.
This change adds the run_for, run_until, run_one_for and run_one_until
functions to the io_context class.
2016-08-25 07:24:34 +10:00